From ac8339c6b4db14c2060c5685ed0e1d880708e82f Mon Sep 17 00:00:00 2001 From: Dominik Schenk Date: Sat, 25 Sep 2021 00:46:02 +0200 Subject: [PATCH] fix: showing correct push/pull numbers --- src/app/shared/components/footer/footer.component.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/app/shared/components/footer/footer.component.ts b/src/app/shared/components/footer/footer.component.ts index f9831a2..ce01600 100644 --- a/src/app/shared/components/footer/footer.component.ts +++ b/src/app/shared/components/footer/footer.component.ts @@ -1,3 +1,4 @@ +import { CommanderService } from './../commander/commander.service'; import { Component, OnInit } from '@angular/core'; import { RepositoryService } from '@routes/repository/repository.service'; import { sleep } from '@shared/functions'; @@ -12,7 +13,8 @@ export class FooterComponent implements OnInit { isSync = false; constructor( - public repositoryService: RepositoryService + public repositoryService: RepositoryService, + private commanderService: CommanderService ) { } ngOnInit(): void { @@ -21,7 +23,9 @@ export class FooterComponent implements OnInit { async sync() { this.isSync = true; await this.repositoryService.sync(); - await sleep(2000); + this.commanderService.reloadData(); + this.repositoryService.loadAheadBehindOfCurrentBranch(); + await sleep(1000); this.isSync = false; } }