minor tweaks; make tests pass