More bug fixes

Down from 53 to 19!