modified controller and model