Skip to content

Commit 98e4204

Browse files
authored
[CLEANUP] Avoid using empty on an integer (#829)
`empty` behaves in mysterious ways and should be avoided.
1 parent 9c00576 commit 98e4204

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Parsing/SourceException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ class SourceException extends \Exception
1818
public function __construct($sMessage, $iLineNo = 0)
1919
{
2020
$this->iLineNo = $iLineNo;
21-
if (!empty($iLineNo)) {
21+
if ($iLineNo !== 0) {
2222
$sMessage .= " [line no: $iLineNo]";
2323
}
2424
parent::__construct($sMessage);

0 commit comments

Comments
 (0)