Skip to content

Commit c671eb6

Browse files
committed
Move lowercase of scheme to Url::__construct()
1 parent 3588017 commit c671eb6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Pdp/Uri/Url.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function __construct(
8181
$query,
8282
$fragment
8383
) {
84-
$this->scheme = $scheme;
84+
$this->scheme = mb_strtolower($scheme, 'UTF-8');
8585
$this->user = $user;
8686
$this->pass = $pass;
8787
$this->host = $host;
@@ -121,7 +121,7 @@ public function __toString()
121121
$url = null;
122122

123123
if ($this->scheme) {
124-
$url .= mb_strtolower($this->scheme, 'UTF-8') . '://';
124+
$url .= $this->scheme . '://';
125125
}
126126

127127
if ($this->user) {

0 commit comments

Comments
 (0)