5

I have created an iMessage app to send MSSticker converting from images.

I have implemented following overridden method:  

override func didStartSending(_ message: MSMessage, conversation: MSConversation) {
        // Called when the user taps the send button.

    // Here I am adding rewards points on every sticker sending
    }

In iOS 10.2.0 it worked fine means rewards points get added but after updating to 10.2.1 is suddenly stopped and now I am no longer get callback to didStartSending method nor didCancelSending is called.

Is this a iOS 10.2.1 bug or should I do with any of the app settings for getting notified with the above method?

Any help would be greatly appreciated.

Amit Ajmera
  • 1,387
  • 10
  • 15
  • Without providing more code, it's quite difficult to find out what is the issue here. Have a look on Apple's documentation page: https://developer.apple.com/documentation/messages/msmessagesappviewcontroller/1649191-didstartsending. – Bogdan Jul 02 '18 at 22:52
  • I found a thread https://forums.developer.apple.com/thread/50359 in which another guy was facing the problem. May be that can help you. – Karthick Ramesh Jul 03 '18 at 01:30

1 Answers1

0

In new update you must have to use below method to send message. If you are not call below method then func didStartSending will not call.

    func insert(_ message: MSMessage, 
completionHandler: ((Error?) -> Void)? = nil)

and also check below things

method does not call if the controller’s presentationStyle property is MSMessagesAppPresentationStyle.transcript, or if its presentationContext property is MSMessagesAppPresentationContext.media.

Rakesh Patel
  • 1,673
  • 10
  • 27