Skip to content

Commit

Permalink
use static constructor to run installer logic because IUserMods might…
Browse files Browse the repository at this point in the history
… be constructed multiple times
  • Loading branch information
boformer committed Nov 16, 2022
1 parent 135a8ac commit b5b6563
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion CitiesHarmony/Mod.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ public class Mod : IUserMod
public string Name => $"Harmony 2.2.2-0";
public string Description => "Mod Dependency";

public Mod()
static Mod()
{
// Try to patch all Harmony 1 assemblies before they are used for patching
// (this is possible due to a change in 1.15.1-f4 that constructs all mods first before calling OnEnabled on any of them)
Expand Down

0 comments on commit b5b6563

Please sign in to comment.