I'm doing tests on a webservice by taking the value of a JSON
that returns (it's an integer) it throws me an error.
To take the value I do it with:
[[respuesta valueForKey:@"code"] integerValue]
The error you're leaving is a:
[__ NSSingleObjectArrayI integerValue]: unrecognized selector sent to instance 0x618000016830
If I make a NSLog
of [respuesta valueForKey:@"code"]
as NSString
I get the number but separated in parentheses and spaces, something like this: ( 1 )
. The 1 would be the value I want to pass to the whole.