fix crash with toolbar option in rb2.99 and later