fixing increment bug on pagination