Fix WE Security issue
Dieser Commit ist enthalten in:
Ursprung
7f14182b8e
Commit
c6e8cad799
@ -86,12 +86,19 @@ public class RegionListener implements Listener {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static final String[] shortcutCommands = {"//1", "//2", "//90", "//-90", "//180", "//p", "//c", "//flopy", "//floppy", "//flopyp", "//floppyp", "//u", "//r"};
|
||||||
|
|
||||||
private boolean isWorldEditCommand(String command) {
|
private boolean isWorldEditCommand(String command) {
|
||||||
|
for(String shortcut : shortcutCommands)
|
||||||
|
if(command.startsWith(shortcut))
|
||||||
|
return true;
|
||||||
|
|
||||||
switch(Core.getVersion()){
|
switch(Core.getVersion()){
|
||||||
case 15:
|
case 12:
|
||||||
return RegionListener_15.isWorldEditCommand(command);
|
|
||||||
default:
|
|
||||||
return RegionListener_12.isWorldEditCommand(command);
|
return RegionListener_12.isWorldEditCommand(command);
|
||||||
|
case 15:
|
||||||
|
default:
|
||||||
|
return RegionListener_15.isWorldEditCommand(command);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -33,15 +33,3 @@ commands:
|
|||||||
lockschem:
|
lockschem:
|
||||||
detonator:
|
detonator:
|
||||||
aliases: dt
|
aliases: dt
|
||||||
|
|
||||||
/1:
|
|
||||||
/2:
|
|
||||||
/180:
|
|
||||||
/90:
|
|
||||||
/-90:
|
|
||||||
/p:
|
|
||||||
/c:
|
|
||||||
/flopy:
|
|
||||||
/flopyp:
|
|
||||||
/u:
|
|
||||||
/r:
|
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren