From 5bf71035ad744af4e6e83dc6fd5d27e3c3c98289 Mon Sep 17 00:00:00 2001
From: Viet Nguyen <3805254+vnugent@users.noreply.github.com>
Date: Sat, 9 Nov 2024 20:08:10 -0800
Subject: [PATCH] fix: check for null and undefined

---
 src/app/api/mobile/login/route.ts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/app/api/mobile/login/route.ts b/src/app/api/mobile/login/route.ts
index 43820125b..d92b221bf 100644
--- a/src/app/api/mobile/login/route.ts
+++ b/src/app/api/mobile/login/route.ts
@@ -59,5 +59,5 @@ export async function POST (request: NextRequest): Promise<any> {
 }
 
 function isNullOrEmpty (str: string | null | undefined): boolean {
-  return str?.trim() === ''
+  return str == null || str?.trim() === ''
 }