Fixed .inherits to work with instanceof