Added optional handler parameter to get component (handler) name. Should probably just take the handler as the second arg but that would break compatability.
Added to error class field so XML validates