Browse Source

also do not crash in debug mode if an image cannot be loaded, may be corrupted, whatnot. it is pretty already, if one wants to investigate, it is easier that way

B. Petersen 2 năm trước cách đây
mục cha
commit
8e5034f941

+ 0 - 1
deltachat-ios/Controller/ContextMenuController.swift

@@ -74,7 +74,6 @@ class ContextMenuController: UIViewController {
 
 
     private func makeImageView(image: UIImage?) -> UIView? {
     private func makeImageView(image: UIImage?) -> UIView? {
         guard let image = image else {
         guard let image = image else {
-            safe_fatalError("unexpected nil value")
             return nil
             return nil
         }
         }
 
 

+ 1 - 1
deltachat-ios/Model/GalleryItem.swift

@@ -70,7 +70,7 @@ class GalleryItem: ContextMenuItem {
         case .webxdc:
         case .webxdc:
             loadWebxdcThumbnail(from: msg)
             loadWebxdcThumbnail(from: msg)
         default:
         default:
-            safe_fatalError("unsupported viewtype - viewtype \(viewtype) not supported.")
+            return
         }
         }
     }
     }