ML-268 "Not set" option is not preselected when editing a logbook photo (#269)

* removed const
This commit is contained in:
Vadim 2025-08-28 21:46:27 +02:00 committed by GitHub
parent 78f4bf96ce
commit 49d0a2175f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -35,7 +35,9 @@ class PickerListTile<T> extends StatelessWidget {
title: title,
selectedValue: Optional(selectedValue),
values: [
const Optional(null),
/// `const Optional(null)` for some reason is not equal to a non-const `Optional(null)`
// ignore: prefer_const_constructors
Optional(null),
...values.toSet().map((e) => Optional(e)),
],
titleAdapter: (context, value) => _titleAdapter(context, value.value),