Replaced two where calls to a criteria call, due to failures during tests