Fix issue when Import Default Challenges Button did not work

This commit is contained in:
BONNe 2019-05-05 23:54:35 +03:00
parent f18c8d0dff
commit d9486bbbdb
2 changed files with 4 additions and 11 deletions

View File

@ -102,7 +102,7 @@ public abstract class CommonGUI
protected static final String IMPORT = "import";
protected static final String DEFAULT = "default";
protected static final String DEFAULT = "defaults";
protected static final String GENERATE = "generate";

View File

@ -384,16 +384,9 @@ public class AdminGUI extends CommonGUI
description = this.user.getTranslation("challenges.gui.descriptions.admin.default-import");
icon = new ItemStack(Material.HOPPER);
clickHandler = (panel, user, clickType, slot) -> {
if (clickType.isRightClick())
{
this.overwriteMode = !this.overwriteMode;
this.build();
}
else
{
// Run import command.
this.user.performCommand(this.topLabel + " " + CHALLENGES + " " + DEFAULT + " " + IMPORT);
}
return true;
};
glow = false;