diff options
Diffstat (limited to 'macosx')
-rw-r--r-- | macosx/main.mm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/macosx/main.mm b/macosx/main.mm index dc65b75606..973db9a861 100644 --- a/macosx/main.mm +++ b/macosx/main.mm @@ -246,7 +246,7 @@ Request request_http(std::string url, std::function<void(Response&)> background_ { Response res; - if ( ! error) + if ( ! error && [response isKindOfClass:[NSHTTPURLResponse class]]) { res.code = [(NSHTTPURLResponse *)response statusCode]; res.body = { (const char *)[data bytes], [data length] }; |