Removed redundant query object checks