问题描述
最近,当我尝试在iOS应用中使用GCM apis时,我开始得到这个错误代码:Error Domain = com.google.gcm Code = 501(null)
我无法在任何地方找到这个意义?这实际上是HTTP状态代码,意思是未实现?
我在这行代码中首先得到错误:
GCMService.sharedInstance()。connectWithHandler(){if(error!= nil){print(error)}}中的错误
调用方法打印此消息:
GCM | GCM注册未准备好授权凭证
,错误是错误域= com.google.gcm代码= 501(null)
发生此错误是因为我正在调用
GCMService .sharedInstance()。connectWithHandler(){error in if(error!= nil){print(error)}}
$ b $
错误域= com.google.gcm代码= 501(null)在收到注册令牌之前,或者未能刷新我的令牌。 )是一个非常糟糕的错误信息。
Recently I start to get this error code whenever I try to use the GCM apis in my iOS app: Error Domain=com.google.gcm Code=501 "(null)"
I couldn't find the meaning of this anywhere? Is that actually the HTTP-status code, meaning Not Implemented?
I'm getting the error first at this line of code:
GCMService.sharedInstance().connectWithHandler() { error in if(error != nil) { print(error) } }
calling the method prints this message :
GCM | GCM registration is not ready with auth credentials
and the error is Error Domain=com.google.gcm Code=501 "(null)"
The error occurred because I was calling
GCMService.sharedInstance().connectWithHandler() { error in if(error != nil) { print(error) } }
before I had received a registration token, or had failed to refresh my token.
"Error Domain=com.google.gcm Code=501 "(null)" " is a really bad error message.
这篇关于iOS GCM错误代码501的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!