How do I test if an NSString is empty in Objective-C?
NSString
You can check if [string length] == 0. This will check if it's a valid but empty string (@"") as well as if it's nil, since calling length on nil will also return 0.
[string length] == 0
length
1.4m articles
1.4m replys
5 comments
57.0k users