Skip to content

Commit

Permalink
Fix crash when Forge tries to display missing mods screen
Browse files Browse the repository at this point in the history
  • Loading branch information
mchorse committed Aug 10, 2020
1 parent 0786321 commit a82e5b5
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,13 @@ public static int getType() {
* CALLED BY ASM INJECTED CODE! (COREMOD) DO NOT MODIFY METHOD SIGNATURE!
*/
public static boolean canSubstitute() {
MinemaConfig config = Minema.instance.getConfig();
if (Minema.instance != null) {
MinemaConfig config = Minema.instance.getConfig();

return config != null && (config.useAlphaScreenshot.get() || (CaptureSession.singleton.isEnabled() && config.useAlpha.get()));
return config != null && (config.useAlphaScreenshot.get() || (CaptureSession.singleton.isEnabled() && config.useAlpha.get()));
}

return false;
}

/**
Expand Down

0 comments on commit a82e5b5

Please sign in to comment.