I'm attempting to integrate GCM into our iOS app. I've followed the instructions to update our project for GCM to no avail. Everything I try to register I get:
Registration to GCM failed with error: The operation couldn’t be completed. (com.google.iid error 1005.)
Which GLLInstance.h say:
/// Should call `startWithConfig:` before requesting token.
kGGLInstanceIDOperationErrorCodeInvalidStart = 1005,
I am calling :
[[GCMService sharedInstance] startWithConfig:[GCMConfig defaultConfig]];
before registering for notifications... There aren't any obvious errors from GCM This IS on a device... (just trying to eliminate the obvious)
What next steps should I try?
As usual as soon as I post a question to SO, the answer leaps out at me.
The routine:
which I knew I was calling in:
right before
was needed in two locations... I missed that. Once I added it just before the call:
in:
everything started working. Delightful...