fixed bug that was causing angular app to be undefined in controllers