Fixed issue: Fix dependency on the HTML class for error catching

See: http://dev.kohanaframework.org/issues/3577
Thanks to @rjd22