-
Notifications
You must be signed in to change notification settings - Fork 51
wsrv provider always strips https from url parameter #192
Copy link
Copy link
Open
Description
Lines 167 to 174 in d60ab8f
| export const generate: URLGenerator<"wsrv"> = (src, operations) => { | |
| const url = new URL("https://wsrv.nl/"); | |
| const srcUrl = typeof src === "string" ? src : src.toString(); | |
| const cleanSrc = srcUrl.replace(/^https?:\/\//, ""); | |
| url.searchParams.set("url", cleanSrc); | |
| const params = operationsGenerator(operations); |
Here const cleanSrc = srcUrl.replace(/^https?:\/\//, ""); strips the leading https from any url, this presents issues for images hosted on servers that only allow https access, for example google cloud storage buckets. (wsrv will use http if no protocol is specified).
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels