title: Add field separately to firestore document
body: <p>The following code creates a firestore collection and adds data to it:  </p>
  
  <pre><code>function saveID(sender_psid,complete){
     let data = new Object();
     data.ID = sender_psid;
     data.TASK = complete;
     data.TIME = new Date();
     db.collection('users').add(data);
  }
  </code></pre>
  
  <p>I want to create another function which adds a field to the document at a different time. I have the following function but am getting the error "TypeError: collectionRef.update is not a function"</p>
  
  <pre><code>function saveImage(sender_psid,image) {
  
  
    let collectionRef = db.collection('users');
  
  
    collectionRef.update({IMG:image}).then(res =&gt; {
    console.log(`Document updated at ${res.updateTime}`);
  });
  }
  </code></pre>