Skip to content

Commit 8dea1d2

Browse files
committed
Handle null path better
1 parent e016902 commit 8dea1d2

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/Behat/Gherkin/Node/FeatureNode.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -254,13 +254,11 @@ public function getLine()
254254
* @param string $file A file path
255255
*
256256
* @return bool
257-
*
258-
* @see https://github.com/symfony/filesystem/blob/master/Filesystem.php
259257
*/
260258
protected function isAbsolutePath($file)
261259
{
262260
if ($file === null) {
263-
@trigger_error(sprintf('Calling "%s()" with a null in the $file argument is deprecated since Symfony 4.4.', __METHOD__), E_USER_DEPRECATED);
261+
throw new InvalidArgumentException('The provided file path must not be null.');
264262
}
265263

266264
return strspn($file, '/\\', 0, 1)

0 commit comments

Comments
 (0)