Fixed undefined "app"