Fixed NPE
This commit is contained in:
parent
4e66ea9e48
commit
b2c95675df
@ -19,7 +19,7 @@ import com.redstoner.misc.Utils;
|
|||||||
import com.redstoner.modules.Module;
|
import com.redstoner.modules.Module;
|
||||||
|
|
||||||
@AutoRegisterListener
|
@AutoRegisterListener
|
||||||
@Version(major = 1, minor = 0, revision = 1, compatible = 1)
|
@Version(major = 1, minor = 0, revision = 2, compatible = 1)
|
||||||
public class AdminNotes implements Module, Listener
|
public class AdminNotes implements Module, Listener
|
||||||
{
|
{
|
||||||
private boolean enabled = false;
|
private boolean enabled = false;
|
||||||
@ -30,6 +30,8 @@ public class AdminNotes implements Module, Listener
|
|||||||
public void onEnable()
|
public void onEnable()
|
||||||
{
|
{
|
||||||
notes = JsonManager.getArray(saveFile);
|
notes = JsonManager.getArray(saveFile);
|
||||||
|
if (notes == null)
|
||||||
|
notes = new JSONArray();
|
||||||
enabled = true;
|
enabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user