entropic-bond 1.34.2 → 1.34.3
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.
|
@@ -13,25 +13,21 @@ class ServerAuth extends ServerAuthService {
|
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
15
|
static get instance() {
|
|
16
|
+
if (!ServerAuth._authService)
|
|
17
|
+
throw new Error(ServerAuth.error.shouldBeRegistered);
|
|
16
18
|
return this._instance || (this._instance = new ServerAuth());
|
|
17
19
|
}
|
|
18
20
|
getUser(userId) {
|
|
19
|
-
if (!ServerAuth._authService)
|
|
20
|
-
throw new Error(ServerAuth.error.shouldBeRegistered);
|
|
21
21
|
return ServerAuth._authService.getUser(userId);
|
|
22
22
|
}
|
|
23
23
|
updateUser(userId, credentials) {
|
|
24
|
-
if (!ServerAuth._authService)
|
|
25
|
-
throw new Error(ServerAuth.error.shouldBeRegistered);
|
|
26
24
|
return ServerAuth._authService.updateUser(userId, credentials);
|
|
27
25
|
}
|
|
28
26
|
setCustomCredentials(userId, customCredentials) {
|
|
29
|
-
if (!ServerAuth._authService)
|
|
30
|
-
throw new Error(ServerAuth.error.shouldBeRegistered);
|
|
31
27
|
return ServerAuth._authService.setCustomCredentials(userId, customCredentials);
|
|
32
28
|
}
|
|
33
29
|
}
|
|
34
30
|
exports.ServerAuth = ServerAuth;
|
|
35
|
-
ServerAuth.error = { shouldBeRegistered: 'You should register a Server Auth service before using the
|
|
31
|
+
ServerAuth.error = { shouldBeRegistered: 'You should register a Server Auth service before using the Server Auth.' };
|
|
36
32
|
ServerAuth._instance = undefined;
|
|
37
33
|
//# sourceMappingURL=server-auth.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server-auth.js","sourceRoot":"","sources":["../../src/server-auth/server-auth.ts"],"names":[],"mappings":";;;AAMA,MAAsB,iBAAiB;CAItC;AAJD,8CAIC;AAED,MAAa,UAAW,SAAQ,iBAAiB;IAGhD,gBAAyB,KA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