]> git.mxchange.org Git - friendica.git/commitdiff
Suppress repetitive "missing cache key ping:events:XX" when there are no upcoming...
authorHypolite Petovan <hypolite@mrpetovan.com>
Wed, 19 Oct 2022 13:17:28 +0000 (09:17 -0400)
committerHypolite Petovan <hypolite@mrpetovan.com>
Wed, 19 Oct 2022 13:17:28 +0000 (09:17 -0400)
src/Module/Notifications/Ping.php

index e8dd0ce2d8a7ec8d67670ac7e1fe792e6c3cf24f..0a2d02390fe1c6e28f3c5c7884dbf3a052039713 100644 (file)
@@ -161,9 +161,7 @@ class Ping extends BaseModule
                                $ev = DBA::selectToArray('event', ['type', 'start'],
                                        ["`uid` = ? AND `start` < ? AND `finish` > ? AND NOT `ignore`",
                                                Session::getLocalUser(), DateTimeFormat::utc('now + 7 days'), DateTimeFormat::utcNow()]);
-                               if (DBA::isResult($ev)) {
-                                       DI::cache()->set($cachekey, $ev, Duration::HOUR);
-                               }
+                               DI::cache()->set($cachekey, $ev, Duration::HOUR);
                        }
 
                        if (DBA::isResult($ev)) {