修复一个NPE错误...

Signed-off-by: 502647092 <jtb1@163.com>
pull/3/HEAD
502647092 2016-02-19 09:34:48 +08:00
parent 82f6c99c01
commit 4ab5a1aa67
2 changed files with 8 additions and 3 deletions

View File

@ -3,7 +3,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>org.maxgamer</groupId>
<artifactId>QuickShop</artifactId>
<version>1.8.2</version>
<version>1.8.3</version>
<description>快捷商店重置版本...</description>
<build>
<finalName>${project.name}</finalName>
@ -56,7 +56,11 @@
<jenkins.url>http://ci.citycraft.cn:8080</jenkins.url>
<env.GIT_COMMIT>DEBUG</env.GIT_COMMIT>
<update.description>&amp;a全新版本 &amp;c虚拟悬浮物(橙子提供 对 就是那个汉化COI的逗比) &amp;e7老板修复逗比BUG...</update.description>
<update.changes>&amp;c修复PlayerInteractEvent错误参数导致GuiShopManager的报错...;&amp;c修复箱子的标题为Null是产生的报错...</update.changes>
<update.changes>
&amp;b1.8.3 - &amp;c修复漏斗传输NPE错误...;
&amp;b1.8.2 - &amp;c修复箱子的标题为Null是产生的报错...;
&amp;b1.8.1 - &amp;c修复PlayerInteractEvent错误参数导致GuiShopManager的报错...;
</update.changes>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<repositories>

View File

@ -61,7 +61,8 @@ public class ProtectListener implements Listener {
final Shop srcshop = getShop(src);
final Shop meshop = getShop(me);
final Shop desshop = getShop(des);
if ((srcshop != null && meshop == null) || (meshop != null && desshop == null) || (srcshop != null && desshop != null && srcshop.getOwner().equalsIgnoreCase(desshop.getOwner()))) {
if ((srcshop != null && meshop == null) || (meshop != null && desshop == null)
|| (srcshop != null && desshop != null && srcshop.getOwner() != null && srcshop.getOwner().equalsIgnoreCase(desshop.getOwner()))) {
e.setCancelled(true);
}
}