From 843f79ff40ff2a4957caf3d6356e9a8efc57c1c3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Fri, 20 Aug 2021 09:30:32 +0200 Subject: [PATCH] Update `coverPhotoHasWebP` in UserRebuilDataWorker --- .../files/lib/system/worker/UserRebuildDataWorker.class.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/wcfsetup/install/files/lib/system/worker/UserRebuildDataWorker.class.php b/wcfsetup/install/files/lib/system/worker/UserRebuildDataWorker.class.php index 77f32e3fc7..ed61d9a67c 100644 --- a/wcfsetup/install/files/lib/system/worker/UserRebuildDataWorker.class.php +++ b/wcfsetup/install/files/lib/system/worker/UserRebuildDataWorker.class.php @@ -297,9 +297,13 @@ class UserRebuildDataWorker extends AbstractRebuildDataWorker $userProfiles->getConditionBuilder()->add("user_table.coverPhotoHash IS NOT NULL"); $userProfiles->readObjects(); foreach ($userProfiles as $userProfile) { + $editor = new UserEditor($userProfile->getDecoratedObject()); $coverPhoto = $userProfile->getCoverPhoto(true); if ($coverPhoto instanceof IWebpUserCoverPhoto) { $coverPhoto->createWebpVariant(); + $editor->update([ + 'coverPhotoHasWebP' => 1, + ]); } } } -- 2.20.1