pagination count fixing