From 904521c89de0bedb2db1cf36e3cba3b928eaa65a Mon Sep 17 00:00:00 2001 From: saturneric Date: Mon, 22 Jan 2024 22:02:15 +0800 Subject: fix: improve ui and solve discovered bugs at version checking module --- src/module/integrated/version_checking_module/SoftwareVersion.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/module/integrated/version_checking_module/SoftwareVersion.cpp') diff --git a/src/module/integrated/version_checking_module/SoftwareVersion.cpp b/src/module/integrated/version_checking_module/SoftwareVersion.cpp index 117212cb..e4077d65 100644 --- a/src/module/integrated/version_checking_module/SoftwareVersion.cpp +++ b/src/module/integrated/version_checking_module/SoftwareVersion.cpp @@ -32,7 +32,7 @@ namespace GpgFrontend::Module::Integrated::VersionCheckingModule { -bool VersionCheckingModule::SoftwareVersion::NeedUpgrade() const { +auto VersionCheckingModule::SoftwareVersion::NeedUpgrade() const -> bool { MODULE_LOG_DEBUG("compair version current {} latest {}, result {}", current_version, latest_version, CompareSoftwareVersion(current_version, latest_version)); @@ -45,12 +45,13 @@ bool VersionCheckingModule::SoftwareVersion::NeedUpgrade() const { CompareSoftwareVersion(current_version, latest_version) < 0; } -bool VersionCheckingModule::SoftwareVersion::VersionWithdrawn() const { +auto VersionCheckingModule::SoftwareVersion::VersionWithdrawn() const -> bool { return loading_done && !current_version_publish_in_remote && current_version_is_a_prerelease && !current_version_is_drafted; } -bool VersionCheckingModule::SoftwareVersion::CurrentVersionReleased() const { +auto VersionCheckingModule::SoftwareVersion::CurrentVersionReleased() const + -> bool { return loading_done && current_version_publish_in_remote; } } // namespace GpgFrontend::Module::Integrated::VersionCheckingModule \ No newline at end of file -- cgit v1.2.3