From 22fe84f32c7048762503ff9e4f6ae88eaec6e4e3 Mon Sep 17 00:00:00 2001 From: Brettflan Date: Fri, 16 Dec 2011 00:29:53 -0600 Subject: [PATCH] Fix for rare SpoutPlayer exception when player logs off while spout features related to them are updating --- src/com/massivecraft/factions/integration/SpoutFeatures.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/com/massivecraft/factions/integration/SpoutFeatures.java b/src/com/massivecraft/factions/integration/SpoutFeatures.java index 905279db..5da0548e 100644 --- a/src/com/massivecraft/factions/integration/SpoutFeatures.java +++ b/src/com/massivecraft/factions/integration/SpoutFeatures.java @@ -219,11 +219,12 @@ public class SpoutFeatures if (viewedFaction == null) return; - SpoutPlayer sPlayer = SpoutManager.getPlayer(viewer.getPlayer()); Player pViewed = viewed.getPlayer(); - if (pViewed == null || viewer.getPlayer() == null) + Player pViewer = viewer.getPlayer(); + if (pViewed == null || pViewer == null) return; + SpoutPlayer sPlayer = SpoutManager.getPlayer(pViewer); String viewedTitle = viewed.getTitle(); Role viewedRole = viewed.getRole();