fixing bugs, testing