diff --git a/.github/AAR Source (Android)/java/com/yasirkula/unity/NativeCameraUtils.java b/.github/AAR Source (Android)/java/com/yasirkula/unity/NativeCameraUtils.java index da04151..5202169 100644 --- a/.github/AAR Source (Android)/java/com/yasirkula/unity/NativeCameraUtils.java +++ b/.github/AAR Source (Android)/java/com/yasirkula/unity/NativeCameraUtils.java @@ -315,8 +315,10 @@ else if( "com.android.providers.downloads.documents".equals( uri.getAuthority() final String id = DocumentsContract.getDocumentId( uri ); if( id.startsWith( "raw:" ) ) // https://stackoverflow.com/a/51874578/2373034 return id.substring( 4 ); - - uri = ContentUris.withAppendedId( Uri.parse( "content://downloads/public_downloads" ), Long.valueOf( id ) ); + else if( id.indexOf( ':' ) < 0 ) // Don't attempt to parse stuff like "msf:NUMBER" (newer Android versions) + uri = ContentUris.withAppendedId( Uri.parse( "content://downloads/public_downloads" ), Long.parseLong( id ) ); + else + return null; } else if( "com.android.providers.media.documents".equals( uri.getAuthority() ) ) { diff --git a/Plugins/NativeCamera/Android/NativeCamera.aar b/Plugins/NativeCamera/Android/NativeCamera.aar index f9e96ab..c8adfe1 100644 Binary files a/Plugins/NativeCamera/Android/NativeCamera.aar and b/Plugins/NativeCamera/Android/NativeCamera.aar differ diff --git a/package.json b/package.json index 3325533..e5e1ca7 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "com.yasirkula.nativecamera", "displayName": "Native Camera", - "version": "1.3.1", + "version": "1.3.2", "documentationUrl": "https://github.com/yasirkula/UnityNativeCamera", "changelogUrl": "https://github.com/yasirkula/UnityNativeCamera/releases", "licensesUrl": "https://github.com/yasirkula/UnityNativeCamera/blob/master/LICENSE.txt",