From 3346cadb84081e0ee02c46a542fb8e3fe5421a01 Mon Sep 17 00:00:00 2001 From: Nikhil Narayana Date: Thu, 24 Jun 2021 09:59:45 -0700 Subject: [PATCH] fix: userId validation not checking capitals --- src/renderer/lib/validateUserId.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/renderer/lib/validateUserId.ts b/src/renderer/lib/validateUserId.ts index 562ea15b0..82fbacc1a 100644 --- a/src/renderer/lib/validateUserId.ts +++ b/src/renderer/lib/validateUserId.ts @@ -11,7 +11,7 @@ export interface ValidateUserIdResponse { export const validateUserId = async (userId: string, timeout = 2500): Promise => { // First check that the user id is only alphanumeric - if (!userId.match(/^[0-9a-z]+$/)) { + if (!userId.match(/^[0-9A-z]+$/)) { throw new Error("Invalid user ID format"); }