Skip to content

Commit

Permalink
Fix crash during tests
Browse files Browse the repository at this point in the history
  • Loading branch information
andreynovikov committed Feb 4, 2024
1 parent c82de56 commit bbcad95
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/src/main/java/mobi/maptrek/fragments/DataList.java
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ public void onViewCreated(@NonNull View view, @Nullable Bundle savedInstanceStat
setDataSource(dataSource, savedInstanceState);
if (dataSource instanceof WaypointDbDataSource) {
mFloatingButton = mFragmentHolder.enableListActionButton(R.drawable.ic_add_location, v -> {
if (!isAdded()) // automated testing presses buttons too quickly
return;
CoordinatesInput.Builder builder = new CoordinatesInput.Builder();
CoordinatesInput coordinatesInput = builder.setCallbacks(DataList.this)
.setTitle(getString(R.string.titleCoordinatesInput))
Expand Down

0 comments on commit bbcad95

Please sign in to comment.