X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FWorker%2FUpdateGServers.php;h=e53754584661cd5ac04e9b8ee02cf3eaeb71f4df;hb=3d8e82d95d9cc76b45a8db301b22c4111f335e1c;hp=486dbc93c225ecfe96d9c96571c7549ba39a85c6;hpb=8d999f54d025cebcaeef9386ae9910def7af52c3;p=friendica.git diff --git a/src/Worker/UpdateGServers.php b/src/Worker/UpdateGServers.php index 486dbc93c2..e537545846 100644 --- a/src/Worker/UpdateGServers.php +++ b/src/Worker/UpdateGServers.php @@ -1,6 +1,6 @@ $total, 'outdated' => $outdated, 'updating' => $limit]); @@ -62,12 +63,15 @@ class UpdateGServers // There are duplicated "url" but not "nurl". So we check both addresses instead of just overwriting them, // since that would mean loosing data. if (!empty($gserver['url'])) { - Worker::add(PRIORITY_LOW, 'UpdateGServer', $gserver['url']); + if (Worker::add(PRIORITY_LOW, 'UpdateGServer', $gserver['url'])) { + $count++; + } } if (!empty($gserver['nurl']) && ($gserver['nurl'] != Strings::normaliseLink($gserver['url']))) { - Worker::add(PRIORITY_LOW, 'UpdateGServer', $gserver['nurl']); + if (Worker::add(PRIORITY_LOW, 'UpdateGServer', $gserver['nurl'])) { + $count++; + } } - $count++; } DBA::close($gservers); Logger::info('Updated servers', ['count' => $count]);