Commit 657ce684 by Sebastián Katzer

Removed support for internal app:// attachments

parent 8767a0f2
...@@ -466,10 +466,6 @@ ...@@ -466,10 +466,6 @@
{ {
return [self urlForAsset:path]; return [self urlForAsset:path];
} }
else if ([path hasPrefix:@"app://"])
{
return [self urlForAppInternalPath:path];
}
else if ([path hasPrefix:@"base64:"]) else if ([path hasPrefix:@"base64:"])
{ {
return [self urlFromBase64:path]; return [self urlFromBase64:path];
...@@ -517,7 +513,7 @@ ...@@ -517,7 +513,7 @@
{ {
NSFileManager* fm = [NSFileManager defaultManager]; NSFileManager* fm = [NSFileManager defaultManager];
NSBundle* mainBundle = [NSBundle mainBundle]; NSBundle* mainBundle = [NSBundle mainBundle];
NSString* bundlePath = [mainBundle bundlePath]; NSString* bundlePath = [mainBundle resourcePath];
if ([path isEqualToString:@"res://icon"]) { if ([path isEqualToString:@"res://icon"]) {
path = @"res://AppIcon60x60@3x.png"; path = @"res://AppIcon60x60@3x.png";
...@@ -563,26 +559,6 @@ ...@@ -563,26 +559,6 @@
} }
/** /**
* URL for an internal app path.
*
* @param [ NSString* ] path A relative file path from main bundle dir.
*
* @return [ NSURL* ]
*/
- (NSURL*) urlForAppInternalPath:(NSString*)path
{
NSFileManager* fm = [NSFileManager defaultManager];
NSBundle* mainBundle = [NSBundle mainBundle];
NSString* absPath = [mainBundle bundlePath];
if (![fm fileExistsAtPath:absPath]) {
NSLog(@"File not found: %@", absPath);
}
return [NSURL fileURLWithPath:absPath];
}
/**
* URL for a base64 encoded string. * URL for a base64 encoded string.
* *
* @param [ NSString* ] base64String Base64 encoded string. * @param [ NSString* ] base64String Base64 encoded string.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment