fix: integrate UpdateService with RefreshService. Ensured UpdateService actions are cleared when executing all actions in RefreshService.
This commit is contained in:
parent
607761c678
commit
cef2690aa8
@ -1,11 +1,12 @@
|
||||
import { Injectable } from '@angular/core';
|
||||
import { UpdateService } from './update.service';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class RefreshService {
|
||||
|
||||
constructor() { }
|
||||
constructor(private updateService: UpdateService) { }
|
||||
|
||||
private actions: Array<() => void> = [];
|
||||
|
||||
@ -19,5 +20,6 @@ export class RefreshService {
|
||||
|
||||
executeAll(): void {
|
||||
this.actions.forEach(action => action());
|
||||
this.updateService.removeAll()
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user