mirror of
https://github.com/BentoBoxWorld/Limits.git
synced 2024-06-28 23:54:58 +02:00
prevent NPE for blockCounts.
This commit is contained in:
parent
390814bedb
commit
b71700895e
|
@ -78,6 +78,9 @@ public class IslandBlockCount implements DataObject {
|
||||||
* @return the blockCount
|
* @return the blockCount
|
||||||
*/
|
*/
|
||||||
public Map<Material, Integer> getBlockCounts() {
|
public Map<Material, Integer> getBlockCounts() {
|
||||||
|
if (blockCounts == null) {
|
||||||
|
blockCounts = new EnumMap<>(Material.class);
|
||||||
|
}
|
||||||
return blockCounts;
|
return blockCounts;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user