Merge remote-tracking branch 'origin/main' into logger
This commit is contained in:
@@ -129,8 +129,9 @@ function buildLineInserts(
|
||||
amount_in_currency: line.amount_in_currency ? Math.round(line.amount_in_currency * 100) / 100 : null,
|
||||
exchange_rate: line.exchange_rate || null,
|
||||
line_description: line.line_description || null,
|
||||
cost_center_id: line.cost_center || null,
|
||||
project_id: line.project || null,
|
||||
tax_code: line.tax_code || null,
|
||||
cost_center: line.cost_center || null,
|
||||
project: line.project || null,
|
||||
sort_order: index,
|
||||
}))
|
||||
}
|
||||
|
||||
+1
-1
@@ -116,5 +116,5 @@ export async function sendEmail(options: SendEmailOptions): Promise<SendEmailRes
|
||||
* Check if Resend is properly configured
|
||||
*/
|
||||
export function isResendConfigured(): boolean {
|
||||
return !!process.env.RESEND_API_KEY
|
||||
return !!process.env.RESEND_API_KEY && !!process.env.RESEND_FROM_EMAIL && process.env.RESEND_FROM_EMAIL !== 'noreply@localhost'
|
||||
}
|
||||
|
||||
@@ -115,7 +115,7 @@ export async function sendReminder(
|
||||
subject: generateReminderEmailSubject(emailData),
|
||||
html: generateReminderEmailHtml(emailData),
|
||||
text: generateReminderEmailText(emailData),
|
||||
replyTo: (company as CompanySettings & { email?: string }).email || undefined,
|
||||
replyTo: company.email || undefined,
|
||||
fromName: company.company_name || undefined
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user