code indented and documentation added to Base controller