swisspol/GCDWebServer

GCDWebUploader doesn't seem to work in the simulator.

Closed this issue · 0 comments

I'm not sure if it's related to the simulator but I can't get initWithUploadDirectory to work.

When trying the example:
NSString* documentsPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES) firstObject]; _webUploader = [[GCDWebUploader alloc] initWithUploadDirectory:documentsPath]; [_webUploader start]; NSLog(@"Visit %@ in your web browser", _webUploader.serverURL);
_webUploader.serverURL will always log (null).

When I use init instead of initWithUploadDirectory:documentsPath, _webUploader.serverURL contains an URL which will show a page with a 501 error.