fixed Application lifecycle functionality