page query bug fix