arky-sdk 0.3.161 → 0.3.162

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/dist/index.cjs CHANGED
@@ -277,11 +277,13 @@ var createAuthApi = (apiConfig) => {
277
277
  },
278
278
  /**
279
279
  * Check if current user is a guest (anonymous)
280
+ * Guest emails follow pattern: guest+uuid@arky.io
280
281
  */
281
282
  async isGuest() {
282
283
  const tokens = await apiConfig.getToken();
283
284
  if (!tokens?.accessToken) return true;
284
- return tokens.isGuest === true;
285
+ const email = tokens.email || "";
286
+ return !email || email.startsWith("guest+");
285
287
  },
286
288
  // ==================== PLATFORM AUTH (Admin) ====================
287
289
  /**