From 5ea25f03ce9f674cd539c08ed5895eadde52e8ce Mon Sep 17 00:00:00 2001 From: Silarn Date: Fri, 12 Apr 2019 21:28:47 -0500 Subject: Rework logic - we want updates that are newer than the last update - 1hr --- src/modinfo.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/modinfo.cpp b/src/modinfo.cpp index ad5c5fb9..c1974152 100644 --- a/src/modinfo.cpp +++ b/src/modinfo.cpp @@ -350,7 +350,7 @@ std::set> ModInfo::filteredMods(QString gameName, QVaria QVariantMap update = result.toMap(); std::copy_if(s_Collection.begin(), s_Collection.end(), std::inserter(finalMods, finalMods.end()), [=](QSharedPointer info) -> bool { if (info->getNexusID() == update["mod_id"].toInt() && info->getGameName().compare(gameName, Qt::CaseInsensitive) == 0) - if (info->getLastNexusUpdate() > QDateTime::fromSecsSinceEpoch(update["latest_file_update"].toInt(), Qt::UTC).addSecs(-3600)) + if (info->getLastNexusUpdate().addSecs(-3600) < QDateTime::fromSecsSinceEpoch(update["latest_file_update"].toInt(), Qt::UTC)) return true; return false; }); -- cgit v1.3.1