Skip to content

Commit

Permalink
profile: prevent accidental "undefined" as profile identifier
Browse files Browse the repository at this point in the history
  • Loading branch information
abarisain authored and arnaud-roland committed Oct 21, 2024
1 parent 9b82b41 commit f169861
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/BatchProfile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ export const BatchProfile = {
* If a profile already exists, this device will be attached to it. Must not be longer than 1024 characters.
*/
identify: (identifier: string | null): void => {
if (typeof identifier === 'undefined') {
return;
}
RNBatch.profile_identify(identifier);
},

Expand Down

0 comments on commit f169861

Please sign in to comment.