Bug
The invite URL generated by createInvite in @emdash-cms/auth/src/invite.ts (line 71) uses /api/auth/invite/accept but the actual route is injected at /_emdash/api/auth/invite/accept.
This causes invite links to 404 when clicked.
Source
// @emdash-cms/auth/src/invite.ts line 71
const url = new URL("/api/auth/invite/accept", config.baseUrl);
The route injection in emdash/src/astro/integration/routes.ts line 777:
pattern: "/_emdash/api/auth/invite/accept",
Expected
Invite URL should be https://example.com/_emdash/api/auth/invite/accept?token=...
Actual
Invite URL is https://example.com/api/auth/invite/accept?token=... — returns 404.
Workaround
Manually change /api/ to /_emdash/api/ in the invite link before sharing with invitees.
Environment
- emdash v0.1.0
- @emdash-cms/auth v0.1.0
- Astro 6.1.1
- @astrojs/cloudflare v13
- Deployed on Cloudflare Workers
Bug
The invite URL generated by
createInvitein@emdash-cms/auth/src/invite.ts(line 71) uses/api/auth/invite/acceptbut the actual route is injected at/_emdash/api/auth/invite/accept.This causes invite links to 404 when clicked.
Source
The route injection in
emdash/src/astro/integration/routes.tsline 777:Expected
Invite URL should be
https://example.com/_emdash/api/auth/invite/accept?token=...Actual
Invite URL is
https://example.com/api/auth/invite/accept?token=...— returns 404.Workaround
Manually change
/api/to/_emdash/api/in the invite link before sharing with invitees.Environment