mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2025-02-17 04:41:40 +01:00
Makes Blueprint Bundle uniqueIds case insensitive
This actually makes them always lowercase in the code. The previous approach of using a case insensitive TreeMap was not possible because it could not handle null values, which could occur if the bundle had no blueprint set for a specific world environment. This approach was the easiest and most straightforward. The assumption here is that the admin was changing the unique name of the blueprint bundle in the JSON file. https://github.com/BentoBoxWorld/BentoBox/issues/865
This commit is contained in:
parent
65aee40533
commit
a5393b117a
@ -3,6 +3,7 @@ package world.bentobox.bentobox.blueprints.dataobjects;
|
||||
import java.util.ArrayList;
|
||||
import java.util.EnumMap;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
|
||||
import org.bukkit.Material;
|
||||
@ -68,7 +69,7 @@ public class BlueprintBundle implements DataObject {
|
||||
*/
|
||||
@Override
|
||||
public String getUniqueId() {
|
||||
return uniqueId;
|
||||
return uniqueId.toLowerCase(Locale.ENGLISH);
|
||||
}
|
||||
/**
|
||||
* @param uniqueId the uniqueId to set
|
||||
|
Loading…
Reference in New Issue
Block a user