Skip to content
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

Remove file_url replacement trailing slash #50

Open
Aerzas opened this issue Aug 15, 2022 · 1 comment
Open

Remove file_url replacement trailing slash #50

Aerzas opened this issue Aug 15, 2022 · 1 comment

Comments

@Aerzas
Copy link

Aerzas commented Aug 15, 2022

To support protocol relative URLs, a slash is added after the replacement but it introduces multiple issues.

When the baseUrl is defined to a domain, it adds an unecessary slash.

When the baseUrl is not defined, it adds an unecessary leading slash.

  • Base Url: /
  • URL: stream://image/dummy.png
  • URL replaced: //image/dummy.png

Note that //image/dummy.png is not a valid protocal-relative URL since there is no domain, a correct URL would be//example.test/image/dummy.png

@Aerzas
Copy link
Author

Aerzas commented Aug 15, 2022

It seems to happen only when the stream wrapper is mapped to an empty string (during development).

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

No branches or pull requests

1 participant