title: Flutter Firestore transaction not running properly
body: <p>I am trying to increase the no. of likes for a name whenever it is tapped. I have used the following cloud firestore query</p>
  
  <pre><code>onTap: () =&gt; Firestore.instance.runTransaction((transaction) async {
              print(Text('hello'));
              DocumentSnapshot freshSnapshot = await transaction.get(record.reference);
              Record fresh = Record.fromSnapShot(freshSnapshot);
              await transaction
                  .update(record.reference, {'votes': fresh.votes + 1});
            }),
  </code></pre>
  
  <p>The above transaction is not reflecting any changes to the database.</p>