Improve handling of isCollection when a resource is defined as a schema