草庐IT

registrationHandler

全部标签

ios - 无法将类型 '(String!, NSError!) -> ()' 的值转换为预期的参数类型 'GGLInstanceIDTokenHandler!'

重构为Swift3后,我在使用GoogleCloudMessaging(GCM)时遇到了这个问题。有人可以帮忙吗?我遇到了这个错误:无法将类型“(String!,NSError!)->()”的值转换为预期的参数类型“GGLInstanceIDTokenHandler!”这里:funcapplication(_application:UIApplication,didRegisterForRemoteNotificationsWithDeviceTokendeviceToken:Data){//...GGLInstanceID.sharedInstance().tokenWithAuth