Fix null pointer

This commit is contained in:
James Cole
2024-01-05 10:55:46 +01:00
parent 25a23801be
commit f9463e02a2
11 changed files with 23 additions and 3 deletions

View File

@@ -31,6 +31,7 @@ use FireflyIII\User;
use Illuminate\Contracts\Auth\Authenticatable;
use Illuminate\Database\Eloquent\Relations\HasMany;
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Log;
/**
* Class RuleGroupRepository.
@@ -152,7 +153,7 @@ class RuleGroupRepository implements RuleGroupRepositoryInterface
public function destroyAll(): void
{
$groups = $this->get();
Log::channel('audit')->info('Delete all rule groups through destroyAll'); $groups = $this->get();
/** @var RuleGroup $group */
foreach ($groups as $group) {