Ensure per_page is an integer