Fixed PHP 8.1 deprecation notice

This commit is contained in:
Bernd Bestel 2022-12-25 20:35:25 +01:00
parent 0229d187ae
commit 639ef0da5b
No known key found for this signature in database
GPG Key ID: 71BD34C0D4891300

View File

@ -49,7 +49,7 @@ class ChoresService extends BaseService
$assignedUsers = [];
foreach ($users as $user)
{
if (in_array($user->id, explode(',', $chore->assignment_config)))
if (!empty($chore->assignment_config) && in_array($user->id, explode(',', $chore->assignment_config)))
{
$assignedUsers[] = $user;
}