mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2024-09-11 04:39:00 +00:00
Protection signs: First check for ownership, then for allowed users.
This commit is contained in:
parent
2690696712
commit
a53d8ddef1
|
@ -146,6 +146,10 @@ public class SignProtection extends EssentialsSign
|
|||
{
|
||||
return SignProtectionState.OWNER;
|
||||
}
|
||||
if (ChatColor.stripColor(sign.getLine(3)).equalsIgnoreCase(username))
|
||||
{
|
||||
return SignProtectionState.OWNER;
|
||||
}
|
||||
for (int i = 1; i <= 2; i++)
|
||||
{
|
||||
final String line = sign.getLine(i);
|
||||
|
@ -158,10 +162,6 @@ public class SignProtection extends EssentialsSign
|
|||
return SignProtectionState.ALLOWED;
|
||||
}
|
||||
}
|
||||
if (ChatColor.stripColor(sign.getLine(3)).equalsIgnoreCase(username))
|
||||
{
|
||||
return SignProtectionState.OWNER;
|
||||
}
|
||||
return SignProtectionState.NOT_ALLOWED;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue