Skip to content

Parse url path to extract query parameters from filename when calling embed.FS#103

Merged
ubogdan merged 2 commits intoswaggo:masterfrom
sapk-fork:fix-filepath-query
Aug 26, 2023
Merged

Parse url path to extract query parameters from filename when calling embed.FS#103
ubogdan merged 2 commits intoswaggo:masterfrom
sapk-fork:fix-filepath-query

Conversation

@sapk
Copy link
Contributor

@sapk sapk commented May 30, 2023

I found that oauth-redirect.html is broken in latest version since it return 404 not found when query parameters are present (which are to be expected during an oauth process)

I think it was introduced in #100

This simply fix the issue by parsing the relative path with url.Parse before sending it to embed.FS.

I added a test similar to what is to be expected from an oauth process.
The same test previously passed successfully on v2.0.0.

@sapk
Copy link
Contributor Author

sapk commented Aug 25, 2023

Hi @ubogdan, sorry to ping you directly.
Could you please have a look at this PR ?

This bug block most oauth logic in swaggerui.

If you don't have time please ignore this message.
I can use my fork in the meantime but it could be great to upstream this fix.

@ubogdan ubogdan merged commit 05e75a5 into swaggo:master Aug 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants