0

I am getting the error

Unexpected token u
code: InternalError
message: Unexpected token u

in web view when I hit the request for authentication

Error

Ujjwal Khatri
  • 716
  • 1
  • 6
  • 19
  • If you include the relevant parts of the error message as text in your post, it can be indexed and someone with the same message can find it using Google or this sites search. – Anthon Apr 03 '15 at 07:04

1 Answers1

1

I solved it.. We also have to provide state parameters with the request.

Ujjwal Khatri
  • 716
  • 1
  • 6
  • 19
  • This helped me out. If anyone else has the issue, this is the code to fix: NSMutableDictionary *options = [[NSMutableDictionary alloc] init]; [options setObject:@"true" forKey:@"cache"]; [options setObject:@"someValue" forKey:@"state"]; [oauthioModal showWithProvider:@"fitbit" options:options]; – Buyin Brian May 29 '15 at 17:49
  • Thanks a lot, too bad this isn't documented properly, but your answer was spot on. – Yuri Doubov Dec 09 '15 at 17:43