Fixing onClose callback in App.Messenger.message