移除realname校验器

v1.18.x
落雨楓 4 years ago
parent 105501c7d9
commit 522077ca50

@ -178,13 +178,13 @@ module.exports = function (User) {
} }
function isFullnameValid(data) { function isFullnameValid(data) {
if (data.fullname && (validator.isURL(data.fullname) || data.fullname.length > 255)) { if (data.fullname && data.fullname.length > 255) {
throw new Error('[[error:invalid-fullname]]'); throw new Error('[[error:invalid-fullname]]');
} }
} }
function isLocationValid(data) { function isLocationValid(data) {
if (data.location && (validator.isURL(data.location) || data.location.length > 255)) { if (data.location && data.location.length > 255) {
throw new Error('[[error:invalid-location]]'); throw new Error('[[error:invalid-location]]');
} }
} }

Loading…
Cancel
Save