|
|
|
|
1
|
package com.RNFetchBlob.Utils;
|
1
|
package com.RNFetchBlob.Utils;
|
2
|
|
2
|
|
|
|
3
|
+import android.annotation.TargetApi;
|
3
|
import android.content.Context;
|
4
|
import android.content.Context;
|
4
|
import android.database.Cursor;
|
5
|
import android.database.Cursor;
|
5
|
import android.net.Uri;
|
6
|
import android.net.Uri;
|
|
|
|
|
15
|
import java.io.FileOutputStream;
|
16
|
import java.io.FileOutputStream;
|
16
|
|
17
|
|
17
|
public class PathResolver {
|
18
|
public class PathResolver {
|
|
|
19
|
+ @TargetApi(19)
|
18
|
public static String getRealPathFromURI(final Context context, final Uri uri) {
|
20
|
public static String getRealPathFromURI(final Context context, final Uri uri) {
|
19
|
|
21
|
|
20
|
final boolean isKitKat = Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT;
|
22
|
final boolean isKitKat = Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT;
|