diff --git a/Tesses.YouTubeDownloader/src/YouTubeDownloader.tcross b/Tesses.YouTubeDownloader/src/YouTubeDownloader.tcross index 7e93e20..f40405a 100644 --- a/Tesses.YouTubeDownloader/src/YouTubeDownloader.tcross +++ b/Tesses.YouTubeDownloader/src/YouTubeDownloader.tcross @@ -97,7 +97,7 @@ class TYTD.Downloader { { var id = TYTD.GetVideoId(id); if(id != null) - PutVideoInfoIfNotExists(id); + this.PutVideoInfoIfNotExists(id); } break; case Resolution.LowVideo: @@ -1457,7 +1457,7 @@ class TYTD.Downloader { { this.Muxex.Lock(); var db = this.OpenDB(); - Sqlite.Exec(db, $"INSERT INTO plugin_settings (extension,key,value) VALUES ({Sqlite.Escape(extension)},{Sqlite.Escape(key)},{Sqlite.Escape(value)});"); + Sqlite.Exec(db, $"INSERT OR REPLACE INTO plugin_settings (extension,key,value) VALUES ({Sqlite.Escape(extension)},{Sqlite.Escape(key)},{Sqlite.Escape(value)});"); Sqlite.Close(db); this.Mutex.Unlock(); }