mirror of
https://github.com/swisspol/GCDWebServer.git
synced 2026-05-13 00:02:02 +08:00
Enable support for Podfiles with use_frameworks!
The previous implementation looked in the main bundle for the GCDWebUploader resource bundle. When using the use_frameworks! Podfile option, the resource bundle will be in a framework bundle, not in the main bundle.
This commit is contained in:
@@ -296,7 +296,7 @@
|
|||||||
|
|
||||||
- (instancetype)initWithUploadDirectory:(NSString*)path {
|
- (instancetype)initWithUploadDirectory:(NSString*)path {
|
||||||
if ((self = [super init])) {
|
if ((self = [super init])) {
|
||||||
NSBundle* siteBundle = [NSBundle bundleWithPath:[[NSBundle mainBundle] pathForResource:@"GCDWebUploader" ofType:@"bundle"]];
|
NSBundle* siteBundle = [NSBundle bundleWithPath:[[NSBundle bundleForClass:[GCDWebUploader class]] pathForResource:@"GCDWebUploader" ofType:@"bundle"]];
|
||||||
if (siteBundle == nil) {
|
if (siteBundle == nil) {
|
||||||
return nil;
|
return nil;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user