API:UnitMaster

Get the master of a unit.
name = UnitMaster(unit)
== Parameter ==
:;unit
::String - the UnitId (e.g. "target", "party1", "raid1", etc..) 
== Returns ==
:;name
::String - name of the unit's master if it has a master. Otherwise nothing.
== Example ==
if UnitMaster("target") then
 ChatFrame1:AddMessage("Your target's master is " .. UnitMaster("target") .. ".")
else
 ChatFrame1:AddMessage("Your target hasn't a master.")
end
UnitMaster