Skip to content
Permalink
Browse files
fix(authentication): set active datadog rum user (DEV-325) (#624)
* refactor(login): new login structure

* refactor(login): new login structure

* refactor(login): new login structure

* refactor(header): clean up code

* refactor(tests): clean up tests

* refactor(login): new login structure

* fix(datadog): re-init data dog user

* test(session): fix tests

* fix(authentication): set active datadog rum user

* fix(authentication): set active datadog rum user
  • Loading branch information
kilchenmann committed Dec 16, 2021
1 parent 2341a84 commit 69308e08010cceba80c40fe5a568b417f5326bb3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
@@ -20,7 +20,7 @@ describe('AuthenticationService', () => {

const cacheServiceSpy = jasmine.createSpyObj('CacheService', ['destroy']);

const datadogRumServiceSpy = jasmine.createSpyObj('datadogRumService', ['removeActiveUser']);
const datadogRumServiceSpy = jasmine.createSpyObj('datadogRumService', ['', 'removeActiveUser']);


beforeEach(() => {
@@ -34,9 +34,11 @@ export class DatadogRumService {
});

// if session is valid: setActiveUser
this._session.isSessionValid().subscribe((response) => {
const session: Session = this._session.getSession();
this.setActiveUser(session.user.name, 'username');
this._session.isSessionValid().subscribe((response: boolean) => {
if (response) {
const session: Session = this._session.getSession();
this.setActiveUser(session.user.name, 'username');
}
});

}

0 comments on commit 69308e0

Please sign in to comment.