diff --git a/src/auth/magic_link/MagicLinkController.ts b/src/auth/magic_link/MagicLinkController.ts index 018529c..fc601af 100644 --- a/src/auth/magic_link/MagicLinkController.ts +++ b/src/auth/magic_link/MagicLinkController.ts @@ -27,7 +27,7 @@ export default abstract class MagicLinkController extends Controller { // Send email await new Mail(mailTemplate, Object.assign(data, { - link: `${req.protocol}://${req.get('host') + Controller.route('magic_link')}?${querystring.stringify({ + link: `${config.get('base_url')}${Controller.route('magic_link')}?${querystring.stringify({ id: link.id, token: token, })}`,