using query.object with namespaces was causing issues when looking for object type