Add some error logs when synchronizing progress can't open the db

This commit is contained in:
luisangelsm
2026-04-12 12:42:59 +02:00
parent 2ad68a8592
commit 0716cbe166

View File

@ -1097,6 +1097,11 @@ QMap<qulonglong, QList<ComicDB>> DBHelper::updateFromRemoteClient(const QMap<qul
{
QSqlDatabase db = DataBaseManagement::loadDatabase(LibraryPaths::libraryDataPath(libraryPath));
if (!db.isValid()) {
QLOG_ERROR() << "updateFromRemoteClient: could not open database for library" << libraryPath;
continue;
}
db.transaction();
QSqlQuery updateComicInfo(db);
@ -1205,6 +1210,11 @@ void DBHelper::updateFromRemoteClientWithHash(const QList<ComicInfo> &comics)
{
QSqlDatabase db = DataBaseManagement::loadDatabase(LibraryPaths::libraryDataPath(libraryPath));
if (!db.isValid()) {
QLOG_ERROR() << "updateFromRemoteClientWithHash: could not open database for library" << libraryPath;
continue;
}
db.transaction();
QSqlQuery updateComicInfo(db);