changing the Angular app controller so it will be minisafe