rafallopatka / ToastNotifications

Toast notifications for WPF allows you to create and display rich notifications in WPF applications. It's highly configurable with set of built-in options like positions, behaviours, themes and many others. It's extendable, it gives you possibility to create custom and interactive notifications in simply manner.
GNU Lesser General Public License v3.0
718 stars 171 forks source link

ClearByTag throws NullReferenceException if there is a notification with a null tag #101

Closed timothylcooke closed 5 years ago

timothylcooke commented 5 years ago

Library version

2.5.1

Expected behaviour

ClearAll(new ClearByTag(tag)) should handle null as its own value. If you set the tag to clear to be null, it should clear any notifications with a null tag. If you set the tag to clear to an instance of an object, it should leave any notifications with a null tag.

Actual behaviour

If there are any notifications with a null tag, a NullReferenceException is thrown when you call ClearAll(new ClearByTag(tag)).

Steps to reproduce behaviour

See above

Code to reproduce behaviour

See above

timothylcooke commented 5 years ago

Please see my pull request: https://github.com/rafallopatka/ToastNotifications/pull/102

rafallopatka commented 5 years ago

Nuget package with provided pull request, will be published soon