modified AppCallback