소스 검색

Removed support for internal app:// attachments

Sebastián Katzer 8 년 전
부모
커밋
657ce68413
1개의 변경된 파일1개의 추가작업 그리고 25개의 파일을 삭제
  1. 1 25
      src/ios/APPNotificationOptions.m

+ 1 - 25
src/ios/APPNotificationOptions.m

@@ -466,10 +466,6 @@
     {
         return [self urlForAsset:path];
     }
-    else if ([path hasPrefix:@"app://"])
-    {
-        return [self urlForAppInternalPath:path];
-    }
     else if ([path hasPrefix:@"base64:"])
     {
         return [self urlFromBase64:path];
@@ -517,7 +513,7 @@
 {
     NSFileManager* fm    = [NSFileManager defaultManager];
     NSBundle* mainBundle = [NSBundle mainBundle];
-    NSString* bundlePath = [mainBundle bundlePath];
+    NSString* bundlePath = [mainBundle resourcePath];
 
     if ([path isEqualToString:@"res://icon"]) {
         path = @"res://AppIcon60x60@3x.png";
@@ -562,26 +558,6 @@
     return [NSURL fileURLWithPath:absPath];
 }
 
-/**
- * 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.
  *