diff --git a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml index 9d6d93c6..82d83dd7 100644 --- a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml +++ b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml @@ -3,11 +3,12 @@ com.massivecraft Factions - 1.6.9.5-U0.2.1-RC-1.5-BETA-2 + 1.6.9.5-U0.2.1-RC-1.5-STABLE 1.6.9.5-U0.2.1-RC-1.5-BETA 1.6.9.5-U0.2.1-RC-1.5-BETA-2 + 1.6.9.5-U0.2.1-RC-1.5-STABLE - 20181221214408 + 20181222234636 diff --git a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.md5 b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.md5 index d3929235..2a0689bb 100644 --- a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.md5 +++ b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.md5 @@ -1 +1 @@ -e9ce0bdae55853de86510ddacb671877 \ No newline at end of file +53a6a6cb7d4b4409eeaa35c1fababa7c \ No newline at end of file diff --git a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.sha1 b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.sha1 index eb588ac4..b765ecc1 100644 --- a/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.sha1 +++ b/mvn-repo/com/massivecraft/Factions/maven-metadata.xml.sha1 @@ -1 +1 @@ -694467945b9eeace46a9acb0cfd0fddc9c87fad8 \ No newline at end of file +6322473e3dc1d937e8d27f82b10f12ac42f8fbb4 \ No newline at end of file diff --git a/pom.xml b/pom.xml index d7c05d33..ac1cdeef 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.massivecraft Factions - 1.6.9.5-U0.2.1-RC-1.5-BETA-2 + 1.6.9.5-U0.2.1-RC-1.5-STABLE jar SavageFactions diff --git a/src/main/java/com/massivecraft/factions/Faction.java b/src/main/java/com/massivecraft/factions/Faction.java index 1ef0434d..0ca31a88 100644 --- a/src/main/java/com/massivecraft/factions/Faction.java +++ b/src/main/java/com/massivecraft/factions/Faction.java @@ -273,7 +273,9 @@ public interface Faction extends EconomyParticipator { FPlayer getFPlayerAdmin(); - ArrayList getFPlayersWhereRole(Role role); + FPlayer getFPlayerLeader(); + + ArrayList getFPlayersWhereRole(Role role); ArrayList getOnlinePlayers(); diff --git a/src/main/java/com/massivecraft/factions/cmd/CmdDisband.java b/src/main/java/com/massivecraft/factions/cmd/CmdDisband.java index dcab1906..80b52a5d 100644 --- a/src/main/java/com/massivecraft/factions/cmd/CmdDisband.java +++ b/src/main/java/com/massivecraft/factions/cmd/CmdDisband.java @@ -47,7 +47,7 @@ public class CmdDisband extends FCommand { if (!fme.isAdminBypassing()) { Access access = faction.getAccess(fme, PermissableAction.DISBAND); - if (fme.getRole() != Role.LEADER && access != Access.ALLOW) { + if (fme.getRole() != Role.LEADER && faction.getFPlayerLeader() != fme && access != Access.ALLOW) { fme.msg(TL.GENERIC_FPERM_NOPERMISSION, "disband " + faction.getTag()); return; } diff --git a/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFaction.java b/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFaction.java index b09f87e8..d59442be 100644 --- a/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFaction.java +++ b/src/main/java/com/massivecraft/factions/zcore/persist/MemoryFaction.java @@ -917,6 +917,7 @@ public abstract class MemoryFaction implements Faction, EconomyParticipator { return ret; } + public FPlayer getFPlayerAdmin() { if (!this.isNormal()) { return null; @@ -930,6 +931,10 @@ public abstract class MemoryFaction implements Faction, EconomyParticipator { return null; } + public FPlayer getFPlayerLeader() { + return getFPlayerAdmin(); + } + public ArrayList getFPlayersWhereRole(Role role) { ArrayList ret = new ArrayList<>(); if (!this.isNormal()) {