Merge pull request #869 from Cube-Space/permission-api
Added getPermissions() to the CommandSender API
This commit is contained in:
@@ -400,6 +400,12 @@ public final class UserConnection implements ProxiedPlayer
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<String> getPermissions()
|
||||
{
|
||||
return Collections.unmodifiableCollection(permissions);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString()
|
||||
{
|
||||
|
@@ -82,4 +82,10 @@ public class ConsoleCommandSender implements CommandSender
|
||||
{
|
||||
throw new UnsupportedOperationException( "Console has all permissions" );
|
||||
}
|
||||
|
||||
@Override
|
||||
public Collection<String> getPermissions()
|
||||
{
|
||||
return Collections.emptySet();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user