Fixed search for nonexisting type using "is_instance" operator.

Currently, the query is considered to be invalid in such case.