Skip to content

Commit b5bcda7

Browse files
authored
Fix unguarded checks spatie#1123
1 parent 317eadb commit b5bcda7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/Traits/LogsActivity.php

+5
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,11 @@ public function shouldLogUnguarded(): bool
244244
if (! $this->activitylogOptions->logUnguarded) {
245245
return false;
246246
}
247+
248+
// This case means model is unguarded
249+
if ($this->isUnguarded()) {
250+
return true;
251+
}
247252

248253
// This case means all of the attributes are guarded
249254
// so we'll not have any unguarded anyway.

0 commit comments

Comments
 (0)