Fixes bug on public DMP view when user is not logged in.

This commit is contained in:
gkolokythas 2019-05-22 17:18:30 +03:00
parent 1ae1f1a91d
commit c98b7934d8
1 changed files with 1 additions and 2 deletions

View File

@ -191,7 +191,7 @@ export class DmpEditorComponent extends BaseComponent implements OnInit, IBreadC
this.formGroup = this.dmp.buildForm(); this.formGroup = this.dmp.buildForm();
this.registerFormEventsForDmpProfile(this.dmp.definition); this.registerFormEventsForDmpProfile(this.dmp.definition);
if (!this.editMode || this.dmp.status === Status.Inactive) { this.formGroup.disable(); } if (!this.editMode || this.dmp.status === Status.Inactive) { this.formGroup.disable(); }
if (this.isAuthenticated) { if (this.isAuthenticated()) {
// if (!this.isAuthenticated) { // if (!this.isAuthenticated) {
this.breadCrumbs = Observable.of([ this.breadCrumbs = Observable.of([
{ {
@ -203,7 +203,6 @@ export class DmpEditorComponent extends BaseComponent implements OnInit, IBreadC
); );
this.associatedUsers = data.associatedUsers; this.associatedUsers = data.associatedUsers;
} }
}); });
} else { } else {
this.dmp = new DmpEditorModel(); this.dmp = new DmpEditorModel();