Lots of hacks to get this to work with 0.8