Changed app controller as per course notes