fixing bugs around unit of work commits