Fixed WorldGuard not getting group lists for permissions correctly.

This commit is contained in:
sk89q 2011-01-17 19:45:53 -08:00
parent 733163cc4c
commit eade612981
3 changed files with 4 additions and 7 deletions

View File

@ -71,7 +71,7 @@ public abstract class LocalPlayer {
* *
* @return * @return
*/ */
public abstract List<String> getGroups(); public abstract String[] getGroups();
@Override @Override
public boolean equals(Object obj) { public boolean equals(Object obj) {

View File

@ -19,7 +19,6 @@
package com.sk89q.worldguard.bukkit; package com.sk89q.worldguard.bukkit;
import java.util.List;
import org.bukkit.Location; import org.bukkit.Location;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import com.sk89q.worldedit.Vector; import com.sk89q.worldedit.Vector;
@ -61,7 +60,7 @@ public void ban(String msg) {
} }
@Override @Override
public List<String> getGroups() { public String[] getGroups() {
return plugin.getGroups(player); return plugin.getGroups(player);
} }

View File

@ -24,9 +24,7 @@
import java.io.FileOutputStream; import java.io.FileOutputStream;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.util.ArrayList;
import java.util.HashSet; import java.util.HashSet;
import java.util.List;
import java.util.Set; import java.util.Set;
import java.util.logging.Level; import java.util.logging.Level;
import java.util.logging.Logger; import java.util.logging.Logger;
@ -369,8 +367,8 @@ boolean hasPermission(Player player, String perm) {
return perms.hasPermission(player.getName(), perm); return perms.hasPermission(player.getName(), perm);
} }
List<String> getGroups(Player player) { String[] getGroups(Player player) {
return new ArrayList<String>(); return perms.getGroups(player.getName());
} }
BukkitPlayer wrapPlayer(Player player) { BukkitPlayer wrapPlayer(Player player) {