-
Notifications
You must be signed in to change notification settings - Fork 73
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
feature(backend): defaulting url trigger to http if no scheme is present #2384
feature(backend): defaulting url trigger to http if no scheme is present #2384
Conversation
} | ||
|
||
if parsedUrl.Scheme == "" { | ||
parsedUrl.Scheme = "http" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we have a constant for this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think a constant is needed here. it's not a value that will be referenced any other place, it's just a default used in this only context.
return response, err | ||
} | ||
|
||
if parsedUrl.Scheme == "" { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to test an edge case: if the address comes with a :443
, should we change this scheme to https
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In that case, we can live with that situation.
…ttp-request-trigger
This PR adds the
http
scheme for URLs that doesn't have it alreadyChanges
Fixes
Checklist
https://www.loom.com/share/e435543d25e741089e5b7f70fa123228