Skip to content

Commit 1b64b6d

Browse files
authored
profile: prevent accidental "undefined" as profile identifier
1 parent 9b82b41 commit 1b64b6d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/BatchProfile.ts

+3
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,9 @@ export const BatchProfile = {
4848
* If a profile already exists, this device will be attached to it. Must not be longer than 1024 characters.
4949
*/
5050
identify: (identifier: string | null): void => {
51+
if (typeof identifier === "undefined") {
52+
return;
53+
}
5154
RNBatch.profile_identify(identifier);
5255
},
5356

0 commit comments

Comments
 (0)