diff --git a/src/com/massivecraft/factions/FPerm.java b/src/com/massivecraft/factions/FPerm.java index fee375ca..08b9f17b 100644 --- a/src/com/massivecraft/factions/FPerm.java +++ b/src/com/massivecraft/factions/FPerm.java @@ -8,7 +8,6 @@ import java.util.Set; import org.bukkit.Location; import org.bukkit.command.CommandSender; import org.bukkit.command.ConsoleCommandSender; -import org.bukkit.entity.Player; import com.massivecraft.factions.iface.RelationParticipator; import com.massivecraft.mcore.ps.PS; @@ -185,7 +184,7 @@ public enum FPerm if (informIfNot) { FPlayer notify = null; - if (testSubject instanceof Player) + if (testSubject instanceof CommandSender) notify = FPlayerColl.get().get(testSubject); else if (testSubject instanceof FPlayer) notify = (FPlayer)testSubject; diff --git a/src/com/massivecraft/factions/cmd/CmdFactionsDeinvite.java b/src/com/massivecraft/factions/cmd/CmdFactionsDeinvite.java index 1c4a61da..19ab214c 100644 --- a/src/com/massivecraft/factions/cmd/CmdFactionsDeinvite.java +++ b/src/com/massivecraft/factions/cmd/CmdFactionsDeinvite.java @@ -4,9 +4,7 @@ import com.massivecraft.factions.FPerm; import com.massivecraft.factions.FPlayer; import com.massivecraft.factions.Factions; import com.massivecraft.factions.Perm; -import com.massivecraft.factions.Rel; import com.massivecraft.factions.cmd.arg.ARFPlayer; -import com.massivecraft.factions.cmd.req.ReqRoleIsAtLeast; import com.massivecraft.mcore.cmd.req.ReqHasPerm; public class CmdFactionsDeinvite extends FCommand diff --git a/src/com/massivecraft/factions/event/FactionDisbandEvent.java b/src/com/massivecraft/factions/event/FactionDisbandEvent.java index 9a9d9b6e..67404dbf 100644 --- a/src/com/massivecraft/factions/event/FactionDisbandEvent.java +++ b/src/com/massivecraft/factions/event/FactionDisbandEvent.java @@ -1,6 +1,6 @@ package com.massivecraft.factions.event; -import org.bukkit.entity.Player; +import org.bukkit.command.CommandSender; import org.bukkit.event.Cancellable; import org.bukkit.event.Event; import org.bukkit.event.HandlerList; @@ -30,7 +30,7 @@ public class FactionDisbandEvent extends Event implements Cancellable // TODO: Could the fields be reorganized to achieve symmetry? private String id; - private Player sender; + private CommandSender sender; public Faction getFaction() { @@ -42,7 +42,7 @@ public class FactionDisbandEvent extends Event implements Cancellable return FPlayer.get(sender); } - public Player getPlayer() + public CommandSender getPlayer() { return this.sender; } @@ -51,7 +51,7 @@ public class FactionDisbandEvent extends Event implements Cancellable // CONSTRUCT // -------------------------------------------- // - public FactionDisbandEvent(Player sender, String factionId) + public FactionDisbandEvent(CommandSender sender, String factionId) { this.cancelled = false; this.sender = sender;