Merge pull request #895 from whatdoineed2do/library-metarescan-fix

Library metarescan fix
This commit is contained in:
ejurgensen 2020-02-08 10:48:02 +01:00 committed by GitHub
commit c5340e350f
2 changed files with 11 additions and 1 deletions

View File

@ -747,7 +747,16 @@ library_init(void)
for (i = 0; sources[i]; i++)
{
if (!sources[i]->init)
continue;
{
DPRINTF(E_LOG, L_LIB, "BUG: library source '%s' has no init()\n", sources[i]->name);
return -1;
}
if (!sources[i]->metarescan)
{
DPRINTF(E_LOG, L_LIB, "BUG: library source '%s' has no metarescan()\n", sources[i]->name);
return -1;
}
ret = sources[i]->init();
if (ret < 0)

View File

@ -1965,6 +1965,7 @@ struct library_source spotifyscanner =
.init = spotifywebapi_init,
.deinit = spotifywebapi_deinit,
.rescan = rescan,
.metarescan = rescan,
.initscan = initscan,
.fullrescan = fullrescan,
.queue_add = queue_add,