moves info from controller to model