fix all the things

this should take care of most existing bugs