referenceId PR feedback + lint fix
This commit is contained in:
parent
869ee217eb
commit
88c8c8ae55
|
@ -79,6 +79,11 @@ export class RegisterComponent extends BaseRegisterComponent {
|
|||
}
|
||||
if (qParams.reference != null) {
|
||||
this.referenceId = qParams.reference;
|
||||
} else {
|
||||
this.referenceId = ('; ' + document.cookie).split('; reference=').pop().split(';').shift();
|
||||
}
|
||||
if (this.referenceId === '') {
|
||||
this.referenceId = null;
|
||||
}
|
||||
if (queryParamsSub != null) {
|
||||
queryParamsSub.unsubscribe();
|
||||
|
@ -99,12 +104,6 @@ export class RegisterComponent extends BaseRegisterComponent {
|
|||
if (this.policies != null) {
|
||||
this.enforcedPolicyOptions = await this.policyService.getMasterPasswordPolicyOptions(this.policies);
|
||||
}
|
||||
|
||||
const referenceId = ('; ' + document.cookie).split('; reference=').pop().split(';').shift();
|
||||
this.referenceId = this.referenceId || referenceId;
|
||||
if (this.referenceId === '') {
|
||||
this.referenceId = null;
|
||||
}
|
||||
}
|
||||
|
||||
async submit() {
|
||||
|
|
|
@ -8,8 +8,8 @@ import { ActivatedRoute } from '@angular/router';
|
|||
|
||||
import { BroadcasterService } from 'jslib/angular/services/broadcaster.service';
|
||||
|
||||
import { UserService } from 'jslib/abstractions/user.service';
|
||||
import { EnvironmentService } from 'jslib/abstractions/environment.service';
|
||||
import { UserService } from 'jslib/abstractions/user.service';
|
||||
|
||||
import { Organization } from 'jslib/models/domain/organization';
|
||||
|
||||
|
|
Loading…
Reference in New Issue