Fix for issue #212 from upstream repo

This commit is contained in:
TheYeti 2012-01-09 18:33:24 -08:00
parent 58b302fd7e
commit 6970174503

View File

@ -16,6 +16,7 @@
*/
package com.gmail.nossr50.skills;
import org.bukkit.craftbukkit.CraftOfflinePlayer;
import org.bukkit.entity.AnimalTamer;
import org.bukkit.entity.Entity;
import org.bukkit.entity.Player;
@ -59,7 +60,13 @@ public class Taming
public static String getOwnerName(Wolf theWolf)
{
Player owner = (Player)theWolf.getOwner();
Player owner = null;
if (theWolf.getOwner() instanceof Player)
{
owner = (Player)theWolf.getOwner();
}
if(owner != null)
{
return owner.getName();