Why don't we instead do this in the cleanup function of a Transaction? Right now it looks like this is unnecessary unless there is some sort of exception.