@alviere/core 0.15.3 → 0.16.1

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.mjs CHANGED
@@ -2356,10 +2356,10 @@ class AlviereCore {
2356
2356
  // Create auth gateway (reuses cached gateway)
2357
2357
  createAuthGateway() {
2358
2358
  if (!this.gateways.has("auth")) {
2359
- if (!this.cryptor) {
2360
- throw new Error("Cryptor not initialized. Cannot create AuthGateway.");
2361
- }
2362
- this.gateways.set("auth", new AuthGateway(this.authToken, this.cryptor, this.logger));
2359
+ this.gateways.set(
2360
+ "auth",
2361
+ new AuthGateway(this.authToken, this.getOrCreateCryptor(), this.logger)
2362
+ );
2363
2363
  }
2364
2364
  return this.gateways.get("auth");
2365
2365
  }