oops, fixed bugs.