@sprucelabs/spruce-invite-utils 7.3.17 → 7.3.19

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.
@@ -41,10 +41,10 @@ export default class LoginAndConfirmJoinControllerImpl {
41
41
  return __awaiter(this, void 0, void 0, function* () {
42
42
  this.client = yield this.connectToApi();
43
43
  this.confirmJoinContext = options === null || options === void 0 ? void 0 : options.confirmJoinViewContext;
44
- if (this.authenticator.isLoggedIn()) {
45
- return true;
44
+ let person = this.authenticator.getPerson();
45
+ if (!this.authenticator.isLoggedIn()) {
46
+ person = yield this.promptForLogin();
46
47
  }
47
- const person = yield this.promptForLogin();
48
48
  if (!person) {
49
49
  return false;
50
50
  }
@@ -38,10 +38,10 @@ class LoginAndConfirmJoinControllerImpl {
38
38
  async promptForLoginAndConfirmJoin(options) {
39
39
  this.client = await this.connectToApi();
40
40
  this.confirmJoinContext = options === null || options === void 0 ? void 0 : options.confirmJoinViewContext;
41
- if (this.authenticator.isLoggedIn()) {
42
- return true;
41
+ let person = this.authenticator.getPerson();
42
+ if (!this.authenticator.isLoggedIn()) {
43
+ person = await this.promptForLogin();
43
44
  }
44
- const person = await this.promptForLogin();
45
45
  if (!person) {
46
46
  return false;
47
47
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sprucelabs/spruce-invite-utils",
3
3
  "description": "Invite Utilities",
4
- "version": "7.3.17",
4
+ "version": "7.3.19",
5
5
  "skill": {
6
6
  "namespace": "invite"
7
7
  },