Reputation: 11
im using OneSignal SDK for PushNotification in my iOS App when i done everything in the Project and run on real device, OneSignal Says : "This user has no push token and cannot be targeted." i checked every thing, ex : codes, profiles.
Upvotes: 0
Views: 508
Reputation: 2241
I was struggling with the same problem.
Are you using objective-c? If so, you need to add the -ObjC flag to your project. Without it, the OneSignal SDK won't work.
On XCode, go to your target project > Build Settings > find Other Linker Flags and add -ObjC Flag.
Sometimes this could generate some conflicts with other SDKs (Such as Parse, GoogleMaps, Facebook..)
Take a look to my answer here for any possibly scenario about this: https://stackoverflow.com/a/39135807/2551707
Upvotes: 1