1

I use the WCSession.defaultSession().sendMessage function to send a message from the watch to the iphone, with non nil replyHandler closure

on the iphone,

    func session(session: WCSession, didReceiveMessage message: [String : AnyObject]) 

is called and not the callback that should be called:

func session(session: WCSession, didReceiveMessage message: [String : AnyObject], replyHandler: ([String : AnyObject]) -> Void)

and thus i cannot call replyHandler :-(

any idea why? thanks a lot!

Edit: code used to make the call:

WCSession.defaultSession().sendMessage(applicationDict, replyHandler: { (reply : [String : AnyObject]) -> Void in
            ...                
        },
        errorHandler: { (er : NSError ) -> Void in
            // Handle error
            print(er.description)
    });
dowi
  • 1,005
  • 15
  • 30
  • could you post the code where you call sendMessage? – ccjensen Mar 08 '16 at 17:24
  • @ccjensen please see the edit. thanks! – dowi Mar 08 '16 at 21:11
  • 1
    that looks like a replyHandler to me. Only way I can imagine we'd be able to help further is a more full code example (test project posted to github, or something like that). Only other option I can suggest is to file a bug report with apple and include a sample project – ccjensen Mar 08 '16 at 23:09

0 Answers0