moved filtering into the controller to assist with pagination attempts