bug fixes

squashing those damn bugs