Skip to content

Commit e4c3633

Browse files
committed
Use UserProfile::ACCESS_EVERYONE constant
1 parent 09048cf commit e4c3633

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ public function execute()
349349
private function updateUserOnlineStatus(array $users): void
350350
{
351351
foreach ($users as $user) {
352-
if (!$user->canViewOnlineStatus) {
352+
if ($user->canViewOnlineStatus == UserProfile::ACCESS_EVERYONE) {
353353
continue;
354354
}
355355
$userProfile = new UserProfile($user->getDecoratedObject());
@@ -358,7 +358,7 @@ private function updateUserOnlineStatus(array $users): void
358358
}
359359

360360
$user->updateUserOptions([
361-
User::getUserOptionID('canViewOnlineStatus') => 0,
361+
User::getUserOptionID('canViewOnlineStatus') => UserProfile::ACCESS_EVERYONE,
362362
]);
363363
}
364364
}

0 commit comments

Comments
 (0)