Fix ContingentViewQueries bug