Fixing#3210 When the place is not null but the descriptions list is empty there was a crash on getting the first element of the Descriptions list. (#3212)

* Deleted values-tt-cryl since it was causing an error and could not build the app.

* Fix for issue #3210: When the place is not null but the descriptions list is empty there was a crash on getting the first element of the Descriptions list. I just check if the list is empty, and in that case I add a new Description to the list.

* Revert "Deleted values-tt-cryl since it was causing an error and could not build the app."

This reverts commit b0f4392a
I reverted deleting the folder.
This commit is contained in:
Ignacio Garcia 2019-11-21 20:12:56 +01:00 committed by Vivek Maskara
parent b7f97aba53
commit 48d70c704d

View file

@ -142,6 +142,9 @@ public class UploadModel {
createdTimestampSource);
if (place != null) {
uploadItem.title.setTitleText(place.name);
if(uploadItem.descriptions.isEmpty()) {
uploadItem.descriptions.add(new Description());
}
uploadItem.descriptions.get(0).setDescriptionText(place.getLongDescription());
uploadItem.descriptions.get(0).setLanguageCode("en");
}