Small fixes to make besh work again