adds the controller for Sorted