]> git.mxchange.org Git - friendica.git/blobdiff - update.php
Fix the tests, hopefully
[friendica.git] / update.php
index 551d208fe4230500c86afc1b8748525e9248c340..aa043468caa9e40ba64483ffba8a406c5fcd666f 100644 (file)
@@ -53,6 +53,7 @@ use Friendica\Model\ItemURI;
 use Friendica\Model\Notification;
 use Friendica\Model\Photo;
 use Friendica\Model\Post;
+use Friendica\Model\Profile;
 use Friendica\Model\Storage;
 use Friendica\Worker\Delivery;
 
@@ -98,8 +99,9 @@ function update_1298()
                                        DBA::update('profile', [$translateKey => $key], ['id' => $data['id']]);
                                        Logger::notice('Updated contact', ['action' => 'update', 'contact' => $data['id'], "$translateKey" => $key,
                                                'was' => $data[$translateKey]]);
-                                       Worker::add(PRIORITY_LOW, 'ProfileUpdate', $data['id']);
+
                                        Contact::updateSelfFromUserID($data['id']);
+                                       Profile::publishUpdate($data['id']);
                                        $success++;
                                }
                        }
@@ -153,7 +155,9 @@ function update_1323()
 {
        $users = DBA::select('user', ['uid']);
        while ($user = DBA::fetch($users)) {
-               Contact::updateSelfFromUserID($user['uid']);
+               if (Contact::updateSelfFromUserID($user['uid'])) {
+                       Profile::publishUpdate($user['uid']);
+               }
        }
        DBA::close($users);