Various minor cleanup

This commit is contained in:
emeric
2024-12-05 20:09:14 +01:00
parent 76b9c1fe10
commit 45175a721c
35 changed files with 104 additions and 137 deletions
+2 -2
View File
@@ -71,11 +71,11 @@ namespace lms::db
return utils::fetchQuerySingleResult(session.getDboSession()->query<Wt::Dbo::ptr<Image>>("SELECT i from image i").where("i.id = ?").bind(id));
}
Image::pointer Image::find(Session& session, const std::filesystem::path& path)
Image::pointer Image::find(Session& session, const std::filesystem::path& file)
{
session.checkReadTransaction();
return utils::fetchQuerySingleResult(session.getDboSession()->query<Wt::Dbo::ptr<Image>>("SELECT i from image i").where("i.absolute_file_path = ?").bind(path));
return utils::fetchQuerySingleResult(session.getDboSession()->query<Wt::Dbo::ptr<Image>>("SELECT i from image i").where("i.absolute_file_path = ?").bind(file));
}
void Image::find(Session& session, ImageId& lastRetrievedImage, std::size_t count, const std::function<void(const Image::pointer&)>& func)