Commit local changes before merge

This commit is contained in:
Matthias Koefferlein 2025-10-19 18:00:43 +02:00
parent c9fde4c3cd
commit 06aa0c48cd
1 changed files with 7 additions and 0 deletions

View File

@ -320,8 +320,15 @@ LibraryController::sync_files ()
try {
std::pair<bool, db::lib_id_type> li = db::LibraryManager::instance ().lib_by_name (lf->second.name, lf->second.tech);
if (li.first) {
if (! lf->second.tech.empty ()) {
tl::log << "Unregistering lib '" << lf->second.name << "' for technology '" << *lf->second.tech.begin () << "' as the file no longer exists: " << lf->first;
} else {
tl::log << "Unregistering lib '" << lf->second.name << "' as the file no longer exists: " << lf->first;
}
db::LibraryManager::instance ().delete_lib (db::LibraryManager::instance ().lib (li.second));
}
} catch (tl::Exception &ex) {
tl::error << ex.msg ();
} catch (...) {
}
}