updates to fix a few bugs