You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not an expert of the RFC documents for urls, I would like to know if the following urls are valid:
This is supposed to have a empty username and empty password (totally different from null username or password)
https://:@domain.com
This is supposed to have empty username and null password
https://@domain.com
This have both username and password null.
https://domain.com
If the second and third statements are true, then Userinfo functions Username and Password should have a mechanism in which should notify to the caller that this values are empty or null.
Password function already returns a bool value indicating presence or nullness of that field. I would like to know if it's correct to have Username function to return the same :)
The text was updated successfully, but these errors were encountered:
The Username method signature cannot change, as it would break go1compat.
That said, UserInfo does already differentiate between itself being nil and the username being empty: https://go.dev/play/p/tOdeqGObADy
Proposal Details
I'm not an expert of the RFC documents for urls, I would like to know if the following urls are valid:
If the second and third statements are true, then
Userinfo
functionsUsername
andPassword
should have a mechanism in which should notify to the caller that this values are empty or null.Password
function already returns a bool value indicating presence or nullness of that field. I would like to know if it's correct to haveUsername
function to return the same :)The text was updated successfully, but these errors were encountered: