Make df work with upcoming snap 1.0

Hey, I was building my webapp with Snap 1 and I needed to make these fixes. Should probably go into a branch until Snap 1 is released...