Small fix

The fix allows the library to work in WPF applications