change checkQuery