updated controller template