Skip to content

Commit 7dd00ef

Browse files
authored
Fixes App crashes on clicking Save (EditActivity) (commons-app#5670)
* Fixed Grey empty screen at Upload wizard caption step after denying files permission * Empty commit * Fixed loop issue * Created docs for earlier commits * Fixed javadoc * Fixed spaces * Added added basic features to OSM Maps * Added search location feature * Added filter to Open Street Maps * Fixed chipGroup in Open Street Maps * Removed mapBox code * Removed mapBox's code * Reformat code * Reformatted code * Removed rotation feature to map * Removed rotation files and Fixed Marker click problem * Ignored failing tests * Added voice input feature * Fixed test cases * Changed caption and description text * Replaced mapbox to osmdroid in upload activity * Fixed Unit Tests * Made selected marker to be fixed on map * Changed color of map marker * Fixes commons-app#5439 by capitalizing first letter of voice input * Removed mapbox code1 * Removed mapbox code2 * Fixed failing tests * Fixed failing due to merging * Added feature to save nearby places as GPX and KML * Fixed error caused by null * Improved UX for Nearby Export * Delete app/src/main/res/values-yue-hant directory * Fixed internationalization issue * Fixed crash
1 parent 5ca3b78 commit 7dd00ef

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

app/src/main/java/fr/free/nrw/commons/edit/EditActivity.kt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -237,8 +237,11 @@ class EditActivity : AppCompatActivity() {
237237
if (rotatedImage == null) {
238238
Toast.makeText(this, "Failed to rotate to image", Toast.LENGTH_LONG).show()
239239
}
240-
val editedImageExif = rotatedImage?.path?.let { ExifInterface(it) }
241-
copyExifData(editedImageExif)
240+
val editedImageExif: ExifInterface?
241+
if (rotatedImage?.path != null) {
242+
editedImageExif = ExifInterface(rotatedImage.path)
243+
copyExifData(editedImageExif)
244+
}
242245
val resultIntent = Intent()
243246
resultIntent.putExtra("editedImageFilePath", rotatedImage?.toUri()?.path ?: "Error");
244247
setResult(RESULT_OK, resultIntent);

0 commit comments

Comments
 (0)