1import { getEnvConf } from '../envConfF.mts'2import { getOptJsonSecretH } from '../secretsF/getReqJsonSecretHF.mts'4export const getExceptionsEmail = () => {5 const { exceptionsToEmail, exceptionsFromEmail } = getEnvConf() as Record<string, string | undefined>6 const { secretVal } = getOptJsonSecretH('exceptionsImapSecretName' as any)7 const derivedEmail = (secretVal as Record<string, any>)?.auth?.user as string | undefined8 return {9 exceptionsToEmail: exceptionsToEmail || derivedEmail,10 exceptionsFromEmail: exceptionsFromEmail || derivedEmail,11 }12}