Merge pull request #407 from Syar-tech/fix-Syar-tech-mimetype

Fix MimeType for API 30
This commit is contained in:
Seph Soliman 2021-06-24 20:20:54 -07:00 committed by GitHub
commit e6c8879824
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -285,7 +285,7 @@ class CKCamera(context: ThemedReactContext) : FrameLayout(context), LifecycleObs
// Create output options object which contains file + metadata // Create output options object which contains file + metadata
val contentValues = ContentValues().apply { val contentValues = ContentValues().apply {
put(MediaStore.MediaColumns.DISPLAY_NAME, "IMG_" + System.currentTimeMillis()) put(MediaStore.MediaColumns.DISPLAY_NAME, "IMG_" + System.currentTimeMillis())
put(MediaStore.MediaColumns.MIME_TYPE, "image/jpg") put(MediaStore.MediaColumns.MIME_TYPE, "image/jpeg")
} }
// Create the output file option to store the captured image in MediaStore // Create the output file option to store the captured image in MediaStore
@ -542,4 +542,4 @@ class CKCamera(context: ThemedReactContext) : FrameLayout(context), LifecycleObs
private const val RATIO_4_3_VALUE = 4.0 / 3.0 private const val RATIO_4_3_VALUE = 4.0 / 3.0
private const val RATIO_16_9_VALUE = 16.0 / 9.0 private const val RATIO_16_9_VALUE = 16.0 / 9.0
} }
} }