Allow new Roblox reset username format
This commit is contained in:
@@ -78,7 +78,8 @@ export async function onRequestPost(context: RequestContext) {
|
|||||||
if (
|
if (
|
||||||
username.length < 3 ||
|
username.length < 3 ||
|
||||||
username.length > 20 ||
|
username.length > 20 ||
|
||||||
username.match(/_/g)?.length > 1 ||
|
(username.match(/_/g)?.length > 1 &&
|
||||||
|
!username.match(/roblox_user_\d+/)) || // New reset username format, the only exception to the underscore rule
|
||||||
username.match(/\W/)
|
username.match(/\W/)
|
||||||
)
|
)
|
||||||
return jsonError(`Username "${username}" is invalid`, 400);
|
return jsonError(`Username "${username}" is invalid`, 400);
|
||||||
|
|||||||
Reference in New Issue
Block a user