fix error when committing with 0 pending transactions