Skip to content

Commit 2703f3e

Browse files
authored
Use arrow function for set_error_handler callback (#48954)
1 parent f58ec8c commit 2703f3e

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/Illuminate/Foundation/Testing/Concerns/InteractsWithDeprecationHandling.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,7 @@ trait InteractsWithDeprecationHandling
2121
protected function withDeprecationHandling()
2222
{
2323
if ($this->originalDeprecationHandler) {
24-
set_error_handler(tap($this->originalDeprecationHandler, function () {
25-
$this->originalDeprecationHandler = null;
26-
}));
24+
set_error_handler(tap($this->originalDeprecationHandler, fn () => $this->originalDeprecationHandler = null));
2725
}
2826

2927
return $this;

0 commit comments

Comments
 (0)