Added hanlding of valid NSData object with 0 bytes for serializers

When handling requests using a serializer (JSON, plist) it is possible that the response will valid `NSData` instance with 0 bytes which means the check for `data == nil` will pass and the serialization calls will fail. To prevent this, we can check if the `NSData` returned has bytes.