From 34f2095263a15dd93679f6dd804b00806a28e716 Mon Sep 17 00:00:00 2001 From: Adhiraj Singh Date: Wed, 27 Jul 2022 12:45:24 +0530 Subject: [PATCH] feat: add check WA business account --- src/Utils/generics.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Utils/generics.ts b/src/Utils/generics.ts index b59da12..edbcdd2 100644 --- a/src/Utils/generics.ts +++ b/src/Utils/generics.ts @@ -346,4 +346,12 @@ export const getCodeFromWSError = (error: Error) => { } return statusCode +} + +/** + * Is the given platform WA business + * @param platform AuthenticationCreds.platform + */ +export const isWABusinessPlatform = (platform: string) => { + return platform === 'smbi' || platform === 'smba' } \ No newline at end of file