Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
fix: sometimes the core dispatcher can't be fetched in constructor #2255
this fix is related to #2154 , some more testing showed that the former bugfix also has to be in place in ScheduleOnDispatcherNow
What kind of change does this PR introduce?
fix related to #2154
What is the current behavior?
When accessing the RxApp.MainThreadScheduler too early (i.e. no MainWindow yet), the CoreDispatcher can't be fetched in SingleWindowDispatcherScheduler's ctor. Thus, ScheduleOnDispatcherNow has to contain the original fix as well (check if _dispatcher is still null and if so, try again fetching the Dispatcher.)
What is the new behavior?
What might this PR break?
Please check if the PR fulfills these requirements