Workaround to fix a crash when using the mini toolbar.