async update(
    id,
    data = {},
  ) {
    const existing = await this.get(id) || {};
    return this.create(
      id,
      existing
        ? {
          ...existing,
          ...data,
        }
        : data,
    );
  }
/** Updates a documents data. If this document does not exist, it will create the document. */
Updates a documents data. If this document does not exist, it will create the document.
Updates a documents data . If this document does not exist it will create the document .
async update(
    id,
    data = {},
  ) {
    const existing = await this.get(id) || {};
    return this.create(
      id,
      existing
        ? {
          ...existing,
          ...data,
        }
        : data,
    );
  }
async update ( id , data = { } , ) { const existing = await this . get ( id ) || { } ; return this . create ( id , existing ? { ... existing , ... data , } : data , ) ; }
Updates a documents data.
Updates a documents data .