Refactor loading of tokens in token component.
This commit is contained in:
parent
a2ee2ae071
commit
02b98a46ca
@ -29,9 +29,11 @@ export class TokensComponent implements OnInit {
|
||||
|
||||
async ngOnInit(): Promise<void> {
|
||||
await this.tokenService.init();
|
||||
this.tokenService.onload = async (status: boolean): Promise<void> => {
|
||||
this.tokenService.load.subscribe(async (status: boolean) => {
|
||||
if (status) {
|
||||
await this.tokenService.getTokens();
|
||||
};
|
||||
}
|
||||
});
|
||||
this.tokenService.tokensSubject.subscribe((tokens) => {
|
||||
this.loggingService.sendInfoLevelMessage(tokens);
|
||||
this.dataSource = new MatTableDataSource(tokens);
|
||||
|
Loading…
Reference in New Issue
Block a user