Hi there,
This behavior has been part of Firestore for a long time, although it has bitten me a few times in the past. Basically it happens when you try to do something like this:
ref.set({
foo: "bar",
baz: undefined
});
As you probably know, "undefined" is a bit of a quirk in JavaScript. Most languages just have values or "null" but JS has "undefined" which is not a value, it's more like a signal about the absence of a value. For this reason Firestore is not able to persist this object, as there's no cross-platform way we can represent the "baz" field. If you were to set baz to "null", it would work.
However if this error is new it suggests that something in your code changed and you probably want to investigate which field is undefined before just ignoring it! Otherwise you may end up writing bad data.
- Sam