Updates UltimateClaims dependency to latest snapshot

This commit is contained in:
Christian Koop 2023-08-25 10:32:20 +02:00
parent 5345452f2a
commit 10f0d28673
No known key found for this signature in database
GPG Key ID: 89A8181384E010A3
2 changed files with 5 additions and 4 deletions

View File

@ -384,7 +384,7 @@
<dependency>
<groupId>com.craftaro</groupId>
<artifactId>UltimateClaims</artifactId>
<version>2.0.0-b2-SNAPSHOT</version>
<version>2.0.0-b4-SNAPSHOT</version>
<scope>provided</scope>
</dependency>

View File

@ -6,6 +6,7 @@ import com.craftaro.ultimateclaims.member.ClaimPerm;
import org.bukkit.Location;
import org.bukkit.entity.Player;
import org.bukkit.plugin.Plugin;
import org.bukkit.plugin.java.JavaPlugin;
public class UltimateClaimsProtection extends Protection {
private final UltimateClaims instance;
@ -13,7 +14,7 @@ public class UltimateClaimsProtection extends Protection {
public UltimateClaimsProtection(Plugin plugin) {
super(plugin);
instance = UltimateClaims.getInstance();
this.instance = JavaPlugin.getPlugin(UltimateClaims.class);
}
@Override
@ -32,7 +33,7 @@ public class UltimateClaimsProtection extends Protection {
}
private boolean hasPerms(Player player, Location location, ClaimPerm claimPerm) {
Claim claim = instance.getClaimManager().getClaim(location.getChunk());
Claim claim = this.instance.getClaimManager().getClaim(location.getChunk());
if (claim == null) {
return true;
}
@ -47,6 +48,6 @@ public class UltimateClaimsProtection extends Protection {
@Override
public boolean isEnabled() {
return instance != null;
return this.instance != null;
}
}