Magic link invalid url and baseURL issue
When I try to generate a magic link, I get this error:
After digging into the stack trace, I noticed that
ctx.context.baseURL
inside the internal package is coming through as undefined
. (screenshot attached)
I haven’t manually set a baseURL
, but when I try to configure one explicitly, everything breaks—the API endpoint no longer works. Instead of the API handler responding, Svelte serves a 404 page (screenshots 2 and 3).
My guess is that the issue lies in Svelte’s routing/handler setup. Setting the baseURL
seems to cause Svelte’s route handling to intercept the request, leading to the 404 page instead of correctly hitting the API.


Solution:Jump to solution
Fixed it: Issue was because it was behind a proxy it recieved http instead of https
1 Reply
Solution
Fixed it: Issue was because it was behind a proxy it recieved http instead of https