mirror of
https://github.com/Multiverse/Multiverse-Core.git
synced 2024-11-22 10:36:06 +01:00
Fixes NPE in MaterialConverter.
This commit is contained in:
parent
b1bf68a0ad
commit
5e067fa72d
@ -32,7 +32,7 @@ public class MaterialConverter {
|
||||
*/
|
||||
@Nullable
|
||||
public static Material convertTypeString(@Nullable String value) {
|
||||
IdMappings.Mapping mapping = IdMappings.getById(value);
|
||||
IdMappings.Mapping mapping = IdMappings.getById(value != null ? value : "");
|
||||
if (mapping != null) {
|
||||
return Material.matchMaterial(mapping.getFlatteningType());
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user