Skip to content
This repository was archived by the owner on Jan 29, 2020. It is now read-only.

Commit 62124e0

Browse files
committed
Set password segment of user info if not null
Previously, a lazy `if ($password)` check meant that a value of `0` would be ignored; it now checks more specifically for `if (null !== $password)`.
1 parent 3db54a5 commit 62124e0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Uri.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ public function withUserInfo($user, $password = null)
291291
}
292292

293293
$info = $this->filterUserInfoPart($user);
294-
if ($password) {
294+
if (null !== $password) {
295295
$info .= ':' . $this->filterUserInfoPart($password);
296296
}
297297

0 commit comments

Comments
 (0)