mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-23 05:36:45 +01:00
Fix incorrect plot count being used in setowner
This commit is contained in:
parent
e93634622c
commit
04df6cefe2
@ -76,7 +76,7 @@ public class SetOwner extends SubCommand {
|
|||||||
else {
|
else {
|
||||||
if (!Permissions.hasPermission(plr, "plots.admin.command.setowner")) {
|
if (!Permissions.hasPermission(plr, "plots.admin.command.setowner")) {
|
||||||
int size = plots.size();
|
int size = plots.size();
|
||||||
final int currentPlots = (Settings.GLOBAL_LIMIT ? MainUtil.getPlayerPlotCount(plr) : MainUtil.getPlayerPlotCount(loc.getWorld(), plr)) + size;
|
final int currentPlots = (Settings.GLOBAL_LIMIT ? MainUtil.getPlayerPlotCount(other) : MainUtil.getPlayerPlotCount(loc.getWorld(), other)) + size;
|
||||||
if (currentPlots > MainUtil.getAllowedPlots(other)) {
|
if (currentPlots > MainUtil.getAllowedPlots(other)) {
|
||||||
sendMessage(plr, C.CANT_TRANSFER_MORE_PLOTS);
|
sendMessage(plr, C.CANT_TRANSFER_MORE_PLOTS);
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
Reference in New Issue
Block a user