Browse Source
fix(events): Don't apply retention before the event happened
Signed-off-by: Joas Schilling <coding@schilljs.com>
pull/15027/head
Joas Schilling
7 months ago
No known key found for this signature in database
GPG Key ID: F72FA5B49FFA96B0
1 changed files with
7 additions and
0 deletions
-
lib/BackgroundJob/ExpireObjectRooms.php
|
|
|
@ -52,6 +52,13 @@ class ExpireObjectRooms extends TimedJob { |
|
|
|
|
|
|
|
$numDeletedRooms = 0; |
|
|
|
foreach ($rooms as $room) { |
|
|
|
if ($objectType === Room::OBJECT_TYPE_EVENT) { |
|
|
|
[, $endTime] = explode('#', $room->getObjectId()); |
|
|
|
if ($endTime < $now) { |
|
|
|
continue; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
$this->roomService->deleteRoom($room); |
|
|
|
$numDeletedRooms++; |
|
|
|
} |
|
|
|
|