react-native-compressor 1.3.0 → 1.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -382,20 +382,17 @@ func makeValidUri(filePath: String) -> String {
|
|
|
382
382
|
|
|
383
383
|
}, completionHandler: { result in
|
|
384
384
|
self.videoCompressionCounter=0;
|
|
385
|
-
|
|
386
|
-
case .success(let status):
|
|
387
|
-
switch status {
|
|
385
|
+
switch exporter.status {
|
|
388
386
|
case .completed:
|
|
389
387
|
onCompletion(exporter.outputURL!)
|
|
390
388
|
break
|
|
389
|
+
case .cancelled:
|
|
390
|
+
let error = CompressionError(message: "Compression has canncelled")
|
|
391
|
+
onFailure(error)
|
|
392
|
+
break
|
|
391
393
|
default:
|
|
392
394
|
onCompletion(url)
|
|
393
395
|
break
|
|
394
|
-
}
|
|
395
|
-
break
|
|
396
|
-
case .failure(let error):
|
|
397
|
-
onCompletion(url)
|
|
398
|
-
break
|
|
399
396
|
}
|
|
400
397
|
})
|
|
401
398
|
}
|