Small fixes

I made some small fixes to make your example work again...