Check `coverPhotoHasWebP` in UserRebuildDataWorker
authorTim Düsterhus <duesterhus@woltlab.com>
Fri, 20 Aug 2021 07:31:14 +0000 (09:31 +0200)
committerTim Düsterhus <duesterhus@woltlab.com>
Fri, 20 Aug 2021 07:31:14 +0000 (09:31 +0200)
This is already checked in `->createWebpVariant()`, but with the `->update()`
added in the previous commit this saves some work.

wcfsetup/install/files/lib/system/worker/UserRebuildDataWorker.class.php

index ed61d9a67c2d0d79b6c4602385bfe2480e04428f..b8b4e2993723aebea05f22fceb3e7efc2cf4bca0 100644 (file)
@@ -295,6 +295,7 @@ class UserRebuildDataWorker extends AbstractRebuildDataWorker
             $userProfiles = new UserProfileList();
             $userProfiles->getConditionBuilder()->add("user_table.userID IN (?)", [$userIDs]);
             $userProfiles->getConditionBuilder()->add("user_table.coverPhotoHash IS NOT NULL");
+            $userProfiles->getConditionBuilder()->add("user_table.coverPhotoHasWebP = ?", [0]);
             $userProfiles->readObjects();
             foreach ($userProfiles as $userProfile) {
                 $editor = new UserEditor($userProfile->getDecoratedObject());