chore: added parallel static data refresh

This commit is contained in:
2026-03-13 23:24:10 +01:00
parent a39acc1cc9
commit 6f51f79c4c
+5 -3
View File
@@ -59,9 +59,11 @@ export const useApiStore = defineStore('apiStore', {
async updateTick(t: number) {
// Static data refresh
if (t >= this.nextDataCheckTime) {
await this.fetchStationsGeneralInfo();
await this.fetchVehiclesInfo();
await this.fetchDonatorsData();
await Promise.all([
this.fetchStationsGeneralInfo(),
this.fetchVehiclesInfo(),
this.fetchDonatorsData()
]);
this.nextDataCheckTime = t + 3600000;
}