Update frontend/src/validation-rules.js

Co-authored-by: Ulf Gebhardt <ulf.gebhardt@webcraft-media.de>
This commit is contained in:
Moriz Wahl 2023-05-19 09:01:07 +02:00 committed by GitHub
parent e007c2a193
commit 36b1a3fb72
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -165,7 +165,7 @@ export const loadAllRules = (i18nCallback, apollo) => {
extend('validIdentifier', {
validate(value) {
const isEmail = !!emailRegex.test(value)
const isEmail = !!EMAIL_REGEX.test(value)
const isUsername = !!value.match(usernameRegex)
const isGradidoId = validateUuid(value) && versionUuid(value) === 4
return isEmail || isUsername || isGradidoId