Skip to content

Commit f786851

Browse files
committed
include errorFile and errorLine into ErrorException
1 parent b2c5fd6 commit f786851

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

spec/Listener/MvcSpec.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -409,8 +409,8 @@
409409
$closure = function () use ($listener) {
410410
$listener->execOnShutdown();
411411
};
412-
expect($closure)->toThrow(new ErrorException('Undefined variable: a', 500, 1));
413-
412+
expect($closure)->toThrow(new ErrorException('Undefined variable: a', 500, 1, '/var/www/zf/module/Application/Module.php', 2));
413+
414414

415415
});
416416

src/HeroTrait.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function phpErrorHandler($errorType, $errorMessage, $errorFile, $errorLin
7777
}
7878

7979
if ($this->errorHeroModuleConfig['display-settings']['display_errors']) {
80-
throw new ErrorException($errorMessage, 500, $errorType);
80+
throw new ErrorException($errorMessage, 500, $errorType, $errorFile, $errorLine);
8181
}
8282
}
8383
}

0 commit comments

Comments
 (0)