did lot of work fixing transactions. not done yet, and not tested.