some bugs squashed :)