update dependendencies

This commit is contained in:
2023-09-07 15:54:40 -05:00
parent ad05ca1366
commit 45a889f035
4 changed files with 116 additions and 192 deletions
+16 -13
View File
@@ -23,19 +23,22 @@ export class AppComponent {
private timezoneService: TimezoneService,
private googleAnalyticsService: GoogleAnalyticsService,
){
this.timezones = this.timezoneService.getTimezones()
var second = interval(1000).pipe(startWith(0))
second.subscribe(()=>{
this.fiveOclocks = [];
this.timezoneService.getCurrentTimeInTimezones(this.timezones).forEach((timezoneObj)=>{
if(timezoneObj.time?.hour === 17){
this.fiveOclocks.push(timezoneObj);
}
})
this.fiveOclock = GetClosestTimezoneFrom(this.timezoneService.getCurrentTimezone(), this.fiveOclocks)
})
const currentTimezone = this.timezoneService.getCurrentTimezone()
if(currentTimezone){
this.timezones = this.timezoneService.getTimezones()
var second = interval(1000).pipe(startWith(0))
second.subscribe(()=>{
this.fiveOclocks = [];
this.timezoneService.getCurrentTimeInTimezones(this.timezones).forEach((timezoneObj)=>{
if(timezoneObj.time?.hour === 17){
this.fiveOclocks.push(timezoneObj);
}
})
this.fiveOclock = GetClosestTimezoneFrom(currentTimezone, this.fiveOclocks)
})
}
}
ngOnInit(): void {