public async Task <IActionResult> SaveVehicles()
        {
            var vehicles = await _wgApi.GetWotEncyclopediaVehiclesAsync();

            await _blitzStatisticsDictionary.SaveVehicles(vehicles);

            return(Ok());
        }
Пример #2
0
        private async Task LoadDictionaries()
        {
            if (_wargamingDictionaries.AreDictionariesCashed)
            {
                return;
            }
            var(languages, nations, vehicleTypes, achievemntSection, clanRoles) = await _wargamingApiClient.GetStaticDictionariesAsync().ConfigureAwait(false);

            var achievementsDictionary = await _wargamingApiClient.GetAchievementsDictionaryAsync().ConfigureAwait(false);

            var vehicles = await _wargamingApiClient.GetWotEncyclopediaVehiclesAsync().ConfigureAwait(false);

            _wargamingDictionaries.SaveToCache(
                nations,
                vehicleTypes,
                achievementsDictionary,
                vehicles);
        }