I got the following error while playing on the MoP beta, and while I know UnitClass now returns a third argument, I don't use it, and thus I'm not sure why it is having issues with the second argument. To cause the error, I used SmartRes2's manual target key bind to give me the pointer, and targeted a character in my party whom was still alive.
[PHP]1x SmartRes2\SmartRes2-MoP-Beta 2.00.lua:661: Usage: UnitClass("unit")
<in C code>
SmartRes2\SmartRes2-MoP-Beta 2.00.lua:661: in function <SmartRes2\SmartRes2.lua:660>
SmartRes2\SmartRes2-MoP-Beta 2.00.lua:694: in function <SmartRes2\SmartRes2.lua:684>
SmartRes2\SmartRes2-MoP-Beta 2.00.lua:709: in function <SmartRes2\SmartRes2.lua:707>
SmartRes2\SmartRes2-MoP-Beta 2.00.lua:738: in function "Resurrection"
SmartRes2\SmartRes2-MoP-Beta 2.00.lua:214: in function <SmartRes2\SmartRes2.lua:214>
It's the UnitClass argument causing the error, not the return.
edit: Actually I have no idea how the raid ids 1-num get handed out, but either way it looks like you're getting a nil result from UnitName, and passing it to UnitClass, and it complains about the nil argument.
Ah yes, I think I understand. Because of the change (GetNumPartyMembers, GetNumRaidMembers --> GetNumGroupMembers) then I don't need the member variable. The altered lines are 47 - 54. That should get a valid unitID now, yes? http://www.wowace.com/paste/5999/