I'm using the Quickblox API to create group chats, which requires UserID's to be sent to methods using the following format:
NSArray *usersIDs = @[@(55), @(678), @(22)];
This array outputs to the log as such:
Correct Format: (
55,
678,
22
)
In my app, I'm filling the array of User ID's to an NSMutableArray, as such:
[holderArray addObject:[users valueForKey:@"ID"]]
Which outputs to the log like this (which, when I send to the method, isn't working):
My Array: (
(
55
),
(
678
), (
22
),
)
Can someone please explain what I'm doing wrong with the holderArray, and how I can get the objects to add in the correct format?
EDIT:
Here is the log output of the users NSArray:
users: (
"
[QBUUser]:
ID:55
created at:2015-08-27 19:33:24 +0000
updated at:2015-08-27 19:33:24 +0000
externalUserID:0
blobID:0
facebookID:(null)
twitterID:(null)
full name:(null)
email:(null)
login:3065555555
phone:(null)
tags:(null)
lastRequestAt:2015-08-29 22:49:34 +0000
customData:(null)
website:(null)"
)
[users valueForKey:@"ID"]isNSArray. Only you can confirm.objectAtIndex:will not work.