fix a bunch of crap