fixed two bugs; prep for interface
oops