Skip to content

Commit eaf7cff

Browse files
committed
Use get method instead of the array
1 parent 99e528e commit eaf7cff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/UrlBuilder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function __construct($url)
4242
*/
4343
public function build($absolute = true)
4444
{
45-
$host = $absolute ? $this->urlParts['scheme'] . '://' . $this->urlParts['host'] . ($this->urlParts['port'] ?? '') : '';
45+
$host = $absolute ? $this->get('scheme') . '://' . $this->get('host') . $this->get('port') : '';
4646
$path = '/' . trim($this->get('path'), '/');
4747

4848
return $host . $path;

0 commit comments

Comments
 (0)