change email validation to regex only

This commit is contained in:
Julian Krauser 2025-05-01 17:36:48 +02:00
parent 753cfdd5da
commit 0ea780dd51
4 changed files with 37 additions and 52 deletions

View file

@ -56,17 +56,12 @@ export default abstract class SettingHelper {
return rawValue as unknown as SettingValueMapping[K];
}
let processedValue = rawValue;
if (typeof settingType.type === "string" && settingType.type.includes("/crypt")) {
processedValue = CodingHelper.decrypt(APPLICATION_SECRET, processedValue);
}
const baseType =
typeof settingType.type === "string"
? (settingType.type.split("/")[0] as SettingTypeAtom)
: (settingType.type as SettingTypeAtom);
return this.converters[baseType].fromString(processedValue) as unknown as SettingValueMapping[K];
return this.converters[baseType].fromString(rawValue) as unknown as SettingValueMapping[K];
}
/**