When creating a new firebase reference using $add() in angularFire it returns a unique reference. Is the uniqueness just within the parent list or is it unique across all lists?

Reason I ask is I seem to have ended up with a duplicate reference in two unassociated lists that I am looking to merge, I cannot merge as the duplicate reference merges two records that should remain separate.

有帮助吗?

解决方案

The $add function internally calls Firebase.push(), which is unique across all paths for a given Firebase instance. These are timestamp-based UUIDs that sort chronologically, and are semi-impossible to obtain a duplicate.

If there are duplicate references in two unassociated lists, then there is more at play here and code that reproduces the error would be necessary to delve any further into the problem.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top