remove useless table
Marco Andronaco andronacomarco@gmail.com
Mon, 15 Jan 2024 17:11:47 +0100
2 files changed,
0 insertions(+),
16 deletions(-)
M
invidious/cache.go
→
invidious/cache.go
@@ -28,11 +28,6 @@ if err != nil {
logger.Errorf("%q: %s\n", err, createQueryVideos) return } - _, err = db.Exec(createQueryFormats) - if err != nil { - logger.Errorf("%q: %s\n", err, createQueryFormats) - return - } } func CacheVideoDB(v Video) error {
M
invidious/queries.go
→
invidious/queries.go
@@ -12,17 +12,6 @@ timestamp DATETIME DEFAULT (datetime('now')),
expire DATETIME NOT NULL );` -const createQueryFormats = ` -CREATE TABLE IF NOT EXISTS formats ( - videoId TEXT, - name TEXT, - height TEXT NOT NULL, - width TEXT NOT NULL, - url TEXT, - PRIMARY KEY (videoId, name), - FOREIGN KEY(videoId) REFERENCES videos(videoId) -);` - const getVideoQuery = "SELECT * FROM videos WHERE videoId = (?);" const cacheVideoQuery = "INSERT OR REPLACE INTO videos (videoId, title, description, uploader, duration, url, expire) VALUES (?, ?, ?, ?, ?, ?, ?);"