From 9359557be08b1f64ba1b1809b3b8c494206126d6 Mon Sep 17 00:00:00 2001 From: Shane Jaroch Date: Wed, 21 Jan 2026 14:20:13 -0500 Subject: [PATCH] lint/fix cache not loaded potential condition --- src/db/foodrepository.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/db/foodrepository.cpp b/src/db/foodrepository.cpp index c878723..2a71346 100644 --- a/src/db/foodrepository.cpp +++ b/src/db/foodrepository.cpp @@ -166,6 +166,7 @@ std::vector FoodRepository::searchFoods(const QString& query) { } std::vector FoodRepository::getFoodNutrients(int foodId) { + ensureCacheLoaded(); std::vector results; QSqlDatabase db = DatabaseManager::instance().database(); -- 2.52.0