fixing up a few bugs