Skip to content

Commit

Permalink
fix(core): prevent fetching update on every page loaded
Browse files Browse the repository at this point in the history
  • Loading branch information
jboulen committed Oct 3, 2024
1 parent b4933fc commit 830e534
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion classes/local/hook_callbacks.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public static function before_footer(before_footer_html_generation $hook): void

// Check update only once a day.
$updateschecker = \core\update\checker::instance();
if ($updateschecker->get_last_timefetched() < (time() + DAYSECS)) {
if ($updateschecker->get_last_timefetched() < (time() - DAYSECS)) {
if ($updateschecker->enabled()) {
$updateschecker->fetch();
}
Expand Down

0 comments on commit 830e534

Please sign in to comment.