title: Error: Argument "data" is not a valid Document. Input is not a plain JavaScript object
body: <p>I am getting the error</p>
  
  <blockquote>
    <p>Error: Argument "data" is not a valid Document. Input is not a plain
    JavaScript object.</p>
  </blockquote>
  
  <p>when updating a document, using firebase admin SDK. Here the Typescript code.</p>
  
  <pre><code>var myDoc = new MyDoc();
  myDoc.Public.Name = "Jonh Doe" //setup up content
  
  admin.firestore()
       .collection('MyDocs')
       .doc("Id1")
       .set(myDoc);
  </code></pre>