XF-Material-Library
XF-Material-Library copied to clipboard
MaterialCheckboxGroup NullReferenceException
🐛 Bug Report
MaterialCheckboxGroup throws a NullReferenceException when both SelectedIndices and Choices and bound to the respective binding properties and Choices is and empty list.
This is due to https://github.com/Baseflow/XF-Material-Library/blob/20bc606a7bc8b9a6ddceb83fc7a3effd4743c1f6/XF.Material/UI/Internals/BaseMaterialSelectionControlGroup.cs#L145 and https://github.com/Baseflow/XF-Material-Library/blob/20bc606a7bc8b9a6ddceb83fc7a3effd4743c1f6/XF.Material/UI/MaterialCheckboxGroup.xaml.cs#L130
the foreach at MaterialCheckboxGroup.xaml.cs#L130 assumes Models to be valid, but due to BaseMaterialSelectionControlGroup.cs#L145 it's not.