Skip to content

Commit

Permalink
feat(app): show drug twice in selection if active again, otherwise mo…
Browse files Browse the repository at this point in the history
…re confusing
  • Loading branch information
tamslo committed Sep 18, 2024
1 parent 5d29503 commit b26bfd8
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/lib/common/widgets/drug_list/builder.dart
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,8 @@ class DrugList extends StatelessWidget {
if (filteredDrugs.isEmpty && noDrugsMessage != null) {
return errorIndicator(noDrugsMessage!);
}
final activeFilteredDrugs = drugActivityChangeable
? drugs.filter((drug) => drug.isActive).toList()
: filteredDrugs.filter((drug) => drug.isActive).toList();
final activeFilteredDrugs =
filteredDrugs.filter((drug) => drug.isActive).toList();
final activeDrugsList = activeFilteredDrugs.isNotEmpty
? buildDrugItems(
context,
Expand Down

0 comments on commit b26bfd8

Please sign in to comment.