This commit is contained in:
@@ -1,9 +1,14 @@
|
|||||||
import nodemailer from 'nodemailer';
|
import nodemailer from 'nodemailer';
|
||||||
import handlebars from 'handlebars';
|
import handlebars from 'handlebars';
|
||||||
import { readFileSync } from 'fs';
|
import { readFileSync } from 'fs';
|
||||||
import { join } from 'path';
|
import { join, dirname } from 'path';
|
||||||
|
import { fileURLToPath } from 'url';
|
||||||
import type { SMTPConfig } from '~/utils/types';
|
import type { SMTPConfig } from '~/utils/types';
|
||||||
|
|
||||||
|
// ES modules compatibility for __dirname
|
||||||
|
const __filename = fileURLToPath(import.meta.url);
|
||||||
|
const __dirname = dirname(__filename);
|
||||||
|
|
||||||
export interface EmailData {
|
export interface EmailData {
|
||||||
to: string;
|
to: string;
|
||||||
subject: string;
|
subject: string;
|
||||||
|
|||||||
Reference in New Issue
Block a user