@cloudbase/auth 2.25.5-alpha.0 → 2.25.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/src/index.ts CHANGED
@@ -2487,7 +2487,7 @@ class Auth {
2487
2487
  return {
2488
2488
  id: userId,
2489
2489
  aud: 'authenticated',
2490
- role: userInfo.groups.map(group => (typeof group === 'string' ? group : group.id)),
2490
+ role: userInfo.groups?.map?.(group => (typeof group === 'string' ? group : group.id)),
2491
2491
  email: email || '',
2492
2492
  email_confirmed_at: userInfo?.email_verified ? userInfo.created_at : userInfo.created_at,
2493
2493
  phone,