summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2011-08-19 01:43:39 +0200
committersnowleo <schneeleo@gmail.com>2011-08-19 01:43:39 +0200
commit521f5f6c070664ad921004ae7958b9058c0ef449 (patch)
tree8b1b39ce9b58c79a03ecdfd912d2f128ff391c9b
parent025ecf330dd1e60ec59d8b512347e57e52d69be2 (diff)
downloadEssentials-521f5f6c070664ad921004ae7958b9058c0ef449.tar
Essentials-521f5f6c070664ad921004ae7958b9058c0ef449.tar.gz
Essentials-521f5f6c070664ad921004ae7958b9058c0ef449.tar.lz
Essentials-521f5f6c070664ad921004ae7958b9058c0ef449.tar.xz
Essentials-521f5f6c070664ad921004ae7958b9058c0ef449.zip
Protection signs: First check for ownership, then for allowed users.
-rw-r--r--Essentials/src/com/earth2me/essentials/signs/SignProtection.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/Essentials/src/com/earth2me/essentials/signs/SignProtection.java b/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
index 43bb964b0..99aa62434 100644
--- a/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
+++ b/Essentials/src/com/earth2me/essentials/signs/SignProtection.java
@@ -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;
}