added some lines in controller

added some lines in controlleradded some lines in controller