Skip to content

Commit 1c85032

Browse files
committed
Set always string $filename on References
1 parent 63e04ac commit 1c85032

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

src/References.php

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,10 @@ public function mergeWith(References $references): References
6868
$merged = clone $this;
6969

7070
foreach ($references as $filename => $lines) {
71-
if (empty($lines)) {
72-
//Check the $filename type
73-
if (gettype($filename) == "integer") {
74-
//Set string
75-
$filename = strval($filename);
76-
}
77-
71+
//Set filename always to string
72+
$filename = (string) $filename;
73+
74+
if (empty($lines)) {
7875
$merged->add($filename);
7976
continue;
8077
}

0 commit comments

Comments
 (0)