(accounts, email)
| 127 | } |
| 128 | |
| 129 | export function findAccountByEmail(accounts, email) { |
| 130 | if (!email || typeof email !== 'string') return null |
| 131 | return ( |
| 132 | accounts.find(a => a?.email && typeof a.email === 'string' && a.email.toLowerCase() === email.toLowerCase()) || |
| 133 | null |
| 134 | ) |
| 135 | } |
| 136 | |
| 137 | export function getRuntimeBase(projectRoot, isDev = false) { |
| 138 | return path.join(projectRoot, isDev ? 'src' : 'dist') |