Fix permissions
This commit is contained in:
parent
bfc4649f80
commit
9c854f732d
3 changed files with 7 additions and 2 deletions
2
pom.xml
2
pom.xml
|
@ -53,7 +53,7 @@
|
|||
<dependency>
|
||||
<groupId>eu.m724</groupId>
|
||||
<artifactId>jarupdater</artifactId>
|
||||
<version>0.1.2</version>
|
||||
<version>0.1.3</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
|
|
@ -51,6 +51,11 @@ public class UpdateCommand {
|
|||
} else {
|
||||
String action = args[1]; // remember this function is proxied
|
||||
|
||||
if (!sender.hasPermission("giants.update." + action)) {
|
||||
sender.sendMessage("You don't have permission to use this command, or it doesn't exist.");
|
||||
return true;
|
||||
}
|
||||
|
||||
if (action.equals("download")) {
|
||||
sender.sendMessage("Started download");
|
||||
|
||||
|
|
|
@ -20,7 +20,7 @@ permissions:
|
|||
description: Permits /giants update. Doesn't permit installing update, giants.update for that
|
||||
default: op
|
||||
|
||||
giants.update.downloading:
|
||||
giants.update.download:
|
||||
description: Permits DOWNLOADING the latest update of the Giants plugin.
|
||||
default: op
|
||||
giants.update.install:
|
||||
|
|
Loading…
Reference in a new issue