fixes to category pagination