Fix bug occured on transaction