From d4244566e81da3e382ce5c172ecd02ddc57e884b Mon Sep 17 00:00:00 2001 From: goat <16760685+goaaats@users.noreply.github.com> Date: Mon, 27 Apr 2020 14:51:39 +0200 Subject: [PATCH] fix: remove asset "version check" --- Dalamud/Interface/AssetManager.cs | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/Dalamud/Interface/AssetManager.cs b/Dalamud/Interface/AssetManager.cs index a6e19bec8..b2e2311d5 100644 --- a/Dalamud/Interface/AssetManager.cs +++ b/Dalamud/Interface/AssetManager.cs @@ -27,17 +27,6 @@ namespace Dalamud.Interface public static async Task EnsureAssets(string baseDir) { using var client = new HttpClient(); - var assetVerRemote = await client.GetStringAsync(AssetStoreUrl + "version"); - - var assetVerPath = Path.Combine(baseDir, "assetver"); - var assetVerLocal = "0"; - if (File.Exists(assetVerPath)) - assetVerLocal = File.ReadAllText(assetVerPath); - - var forceRedownload = assetVerLocal != assetVerRemote; - if (forceRedownload) - Log.Information("Assets need redownload"); - Log.Verbose("Starting asset download"); foreach (var entry in AssetDictionary) { @@ -45,7 +34,7 @@ namespace Dalamud.Interface Directory.CreateDirectory(Path.GetDirectoryName(filePath)); - if (!File.Exists(filePath) || forceRedownload) { + if (!File.Exists(filePath)) { Log.Verbose("Downloading {0} to {1}...", entry.Key, entry.Value); try { File.WriteAllBytes(filePath, await client.GetByteArrayAsync(entry.Key)); @@ -56,13 +45,6 @@ namespace Dalamud.Interface } } - - try { - File.WriteAllText(assetVerPath, assetVerRemote); - } catch (Exception ex) { - Log.Error(ex, "Could not write asset version."); - } } - } }