File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -368,7 +368,7 @@ public static function isAbsolute(string $path): bool
368
368
}
369
369
370
370
// Strip scheme
371
- if (false !== $ schemeSeparatorPosition = strpos ($ path , ':// ' )) {
371
+ if (false !== ( $ schemeSeparatorPosition = strpos ($ path , ':// ' )) && 1 !== $ schemeSeparatorPosition ) {
372
372
$ path = substr ($ path , $ schemeSeparatorPosition + 3 );
373
373
}
374
374
Original file line number Diff line number Diff line change @@ -375,6 +375,8 @@ public static function provideIsAbsolutePathTests(): \Generator
375
375
376
376
yield ['C:/css/style.css ' , true ];
377
377
yield ['D:/ ' , true ];
378
+ yield ['C:///windows ' , true ];
379
+ yield ['C://test ' , true ];
378
380
379
381
yield ['E: \\css \\style.css ' , true ];
380
382
yield ['F: \\' , true ];
You can’t perform that action at this time.
0 commit comments