Skip to content

Commit 331dcc0

Browse files
committed
url path parsing improvement
1 parent 16c0d61 commit 331dcc0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/Url.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -512,10 +512,10 @@ public function getAbsolute($url)
512512
*/
513513
private function setPath($path)
514514
{
515+
$this->info['path'] = $this->info['file'] = $this->info['extension'] = $this->info['content'] = null;
516+
515517
if ($this->getScheme() === 'data') {
516518
$this->info['content'] = $path;
517-
$this->info['path'] = $this->info['file'] = $this->info['extension'] = null;
518-
519519
return;
520520
}
521521

@@ -531,7 +531,6 @@ private function setPath($path)
531531
$this->info['extension'] = $match[2];
532532
} else {
533533
$this->info['file'] = $file;
534-
$this->info['extension'] = null;
535534
}
536535
}
537536

0 commit comments

Comments
 (0)