WIP replaygain support

This commit is contained in:
emeric
2020-04-25 14:39:49 +02:00
parent 4749fd7548
commit f41b6c38a7
22 changed files with 480 additions and 216 deletions
+9 -1
View File
@@ -40,7 +40,7 @@
namespace Database {
#define LMS_DATABASE_VERSION 21
#define LMS_DATABASE_VERSION 22
using Version = std::size_t;
@@ -246,6 +246,14 @@ CREATE TABLE "user_backup" (
{
_session.execute("DROP TABLE subsonic_settings");
}
else if (version == 21)
{
_session.execute("ALTER TABLE track ADD track_replay_gain REAL");
_session.execute("ALTER TABLE track ADD release_replay_gain REAL");
// Just increment the scan version of the settings to make the next scheduled scan rescan everything
ScanSettings::get(*this).modify()->incScanVersion();
}
else
{
LMS_LOG(DB, ERROR) << "Database version " << version << " cannot be handled using migration";