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:
Nick SzaunigandClaude Opus 5 committed 2026-09-15 10:01:18 +02:00
1 parent 4b76247648
commit 18d1bd28bf
1 file changed
+3 -3
+3 -3
View File
@@ -1,5 +1,5 @@
import { formatPrice } from "@/lib/format";
import { siteConfig } from "@/lib/site-config";
import { getSiteUrl } from "@/lib/url";
import { getCompanyInfo } from "@/lib/company-info";
import { getEmailStrings } from "@/lib/email-strings";
import type { Locale } from "@/i18n/config";
@@ -284,7 +284,7 @@ interface BackInStockInput {
export async function backInStockEmail(product: BackInStockInput): Promise<EmailContent> {
const s = getEmailStrings(product.locale).backInStock;
const url = `https://${siteConfig.domain}/honig/${product.slug}`;
const url = `${getSiteUrl()}/honig/${product.slug}`;
const html = await emailLayout(
product.locale,
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
// einen tatsaechlich anklickbaren Button dazu bliebe das ein reiner
// Lauftext-Hinweis ohne direkten Weg zurueck in den Shop.
const shopUrl = `https://${siteConfig.domain}/shop`;
const shopUrl = `${getSiteUrl()}/shop`;
const html = await emailLayout(
order.locale,
s.preheader(order.orderNumber),