Made app run correctly