Method `ensureError` doesn't work correct for inheritance classes

`ensureError` should return instance of parent class for this method.

This is simple example for this issue:
```javascript
try {
    throw new Terror('foo');
} catch(err) {
   console.log(MyError.ensureError(err) instanceof MyError); // false, but why?
}
```