Skip to content

Commit

Permalink
ModuleScriptEditor: Override itself when updating
Browse files Browse the repository at this point in the history
  • Loading branch information
Emik03 committed Aug 21, 2021
1 parent be0460f commit 5890710
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Source/Editors/ModuleScriptEditor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ namespace KeepCoding.Internal
[CanEditMultipleObjects, CustomEditor(typeof(ModuleScript), true)]
public sealed class ModuleScriptEditor : Editor
{
private static string SelfPath => GetDirectoryName(UnescapeDataString(new UriBuilder(GetExecutingAssembly().CodeBase).Path));
private static string SelfPath => UnescapeDataString(new UriBuilder(GetExecutingAssembly().CodeBase).Path);

/// <summary>
/// Creates the colorblind button.
Expand Down Expand Up @@ -84,7 +84,7 @@ private static IEnumerator InstallLatest(string tagName, string extension)

Self($"Installing the latest {extension} file...");

WriteAllBytes(Combine(SelfPath, $"KeepCoding {tagName}.{extension}"), UTF8.GetBytes(web.downloadHandler.text));
WriteAllBytes(SelfPath, web.downloadHandler.data);
}
}
}
Expand Down

0 comments on commit 5890710

Please sign in to comment.