-
Notifications
You must be signed in to change notification settings - Fork 79
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix match-ports to handle a null input port #435
Conversation
I have the impression that the |
Another problem here is that default port is an integer, not a string. |
Also, the caller can pass in null which isn't the empty string, that's another problem. |
I am confused. Looking at where the algorithm is called, a url's port should be either So is a url's port a nullable integer or a string? |
It links the wrong concepts. For host too. That should use |
Ok, so the inputs of the algorithm are actually a string or |
It is however confusing that one of the ports is a string and the other an integer. |
In part this stems from the CSP parser not being defined in detail I suspect. |
5769bd0
to
2179a59
Compare
Coming back to this. Parts of the issue is fixed, but the "port-part matches" algorithm is still expecting a non-null possibly-empty string while being called with null or a non-empty string. I've updated the PR to fix that. |
2179a59
to
7a30255
Compare
SHA: 398a20e Reason: push, by antosart Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Preview | Diff