fix: Produkt- und Shop-Links in E-Mails ueber dieselbe Domain-Quelle
Nachzug zu d3020cd: email-templates.ts nutzte fuer den Bestaetigungs-Link
bereits getBaseUrl(), fuer den Produkt- und den Shop-Link in derselben
Datei aber weiterhin "https://" + siteConfig.domain. Eine
Wiederverfuegbarkeits-Mail konnte dadurch einen Link auf eine andere Domain
enthalten als die Bestellbestaetigung daneben.
Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
This commit is contained in:
1 parent
4b76247648
commit
18d1bd28bf
1 file changed
+3
-3
@@ -1,5 +1,5 @@
|
|||||||
import { formatPrice } from "@/lib/format";
|
import { formatPrice } from "@/lib/format";
|
||||||
import { siteConfig } from "@/lib/site-config";
|
import { getSiteUrl } from "@/lib/url";
|
||||||
import { getCompanyInfo } from "@/lib/company-info";
|
import { getCompanyInfo } from "@/lib/company-info";
|
||||||
import { getEmailStrings } from "@/lib/email-strings";
|
import { getEmailStrings } from "@/lib/email-strings";
|
||||||
import type { Locale } from "@/i18n/config";
|
import type { Locale } from "@/i18n/config";
|
||||||
@@ -284,7 +284,7 @@ interface BackInStockInput {
|
|||||||
|
|
||||||
export async function backInStockEmail(product: BackInStockInput): Promise<EmailContent> {
|
export async function backInStockEmail(product: BackInStockInput): Promise<EmailContent> {
|
||||||
const s = getEmailStrings(product.locale).backInStock;
|
const s = getEmailStrings(product.locale).backInStock;
|
||||||
const url = `https://${siteConfig.domain}/honig/${product.slug}`;
|
const url = `${getSiteUrl()}/honig/${product.slug}`;
|
||||||
const html = await emailLayout(
|
const html = await emailLayout(
|
||||||
product.locale,
|
product.locale,
|
||||||
s.preheader(product.name),
|
s.preheader(product.name),
|
||||||
@@ -357,7 +357,7 @@ export async function paymentFailedEmail(order: OrderStatusUpdateInput): Promise
|
|||||||
// Der Text (retryNote) fordert bereits zur erneuten Bestellung auf — ohne
|
// Der Text (retryNote) fordert bereits zur erneuten Bestellung auf — ohne
|
||||||
// einen tatsaechlich anklickbaren Button dazu bliebe das ein reiner
|
// einen tatsaechlich anklickbaren Button dazu bliebe das ein reiner
|
||||||
// Lauftext-Hinweis ohne direkten Weg zurueck in den Shop.
|
// Lauftext-Hinweis ohne direkten Weg zurueck in den Shop.
|
||||||
const shopUrl = `https://${siteConfig.domain}/shop`;
|
const shopUrl = `${getSiteUrl()}/shop`;
|
||||||
const html = await emailLayout(
|
const html = await emailLayout(
|
||||||
order.locale,
|
order.locale,
|
||||||
s.preheader(order.orderNumber),
|
s.preheader(order.orderNumber),
|
||||||
|
|||||||
Reference in new issue
Block a user