Fixing transaction refund functionality