Fix chosen location not being sent sometimes.

This commit is contained in:
Clark
2023-06-06 11:42:24 -04:00
committed by Cody Henthorne
parent eae066b3a2
commit c491c9dc8c
5 changed files with 105 additions and 39 deletions

View File

@@ -734,9 +734,13 @@ public class ConversationParentFragment extends Fragment
}, nothing -> onRecipientChanged(recipient.get()));
break;
case PICK_LOCATION:
SignalPlace place = new SignalPlace(PlacePickerActivity.addressFromData(data));
attachmentManager.setLocation(place, getCurrentMediaConstraints());
draftViewModel.setLocationDraft(place);
if (data.getData() != null) {
SignalPlace place = new SignalPlace(PlacePickerActivity.addressFromData(data));
attachmentManager.setLocation(place, data.getData());
draftViewModel.setLocationDraft(place);
} else {
Log.w(TAG, "Location missing thumbnail");
}
break;
case SMS_DEFAULT:
viewModel.updateSecurityInfo();