mirror of
https://github.com/dreamhunter2333/cloudflare_temp_email.git
synced 2026-05-21 08:10:48 +08:00
feat: add ADDRESS_CHECK_REGEX (#415)
This commit is contained in:
@@ -41,7 +41,13 @@ api.post('/admin/new_address', async (c) => {
|
||||
return c.text("Please provide a name", 400)
|
||||
}
|
||||
try {
|
||||
const res = await newAddress(c, name, domain, enablePrefix, false, null, false);
|
||||
const res = await newAddress(c, {
|
||||
name, domain, enablePrefix,
|
||||
checkLengthByConfig: false,
|
||||
addressPrefix: null,
|
||||
checkAllowDomains: false,
|
||||
enableCheckNameRegex: false,
|
||||
});
|
||||
return c.json(res);
|
||||
} catch (e) {
|
||||
return c.text(`Failed create address: ${(e as Error).message}`, 400)
|
||||
|
||||
Reference in New Issue
Block a user