geforkt von Mirrors/Paper
Fix for plugin description file cast error
By: stevenh <steven.hartland@multiplay.co.uk>
Dieser Commit ist enthalten in:
Ursprung
c16bd08b18
Commit
b9885402a6
@ -35,7 +35,7 @@ public final class PluginDescriptionFile {
|
|||||||
public PluginDescriptionFile(final Reader reader) {
|
public PluginDescriptionFile(final Reader reader) {
|
||||||
loadMap((Map<String, Object>)yaml.load(reader));
|
loadMap((Map<String, Object>)yaml.load(reader));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a new PluginDescriptionFile with the given detailed
|
* Creates a new PluginDescriptionFile with the given detailed
|
||||||
*
|
*
|
||||||
@ -65,7 +65,7 @@ public final class PluginDescriptionFile {
|
|||||||
public String getName() {
|
public String getName() {
|
||||||
return name;
|
return name;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the version of a plugin
|
* Returns the version of a plugin
|
||||||
*
|
*
|
||||||
@ -85,9 +85,9 @@ public final class PluginDescriptionFile {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void loadMap(Map<String, Object> map) throws ClassCastException {
|
private void loadMap(Map<String, Object> map) throws ClassCastException {
|
||||||
name = (String)map.get("name");
|
name = map.get("name").toString();
|
||||||
main = (String)map.get("main");
|
main = map.get("main").toString();
|
||||||
version = (String)map.get("version");
|
version = map.get("version").toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
private Map<String, Object> saveMap() {
|
private Map<String, Object> saveMap() {
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren