mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-10 13:23:40 -05:00
We can't guarantee that elements we stored a reference to with `classesToPersist.remove` will still exist so we need to guard against this. Note: it checks for whether the node is still attached to the DOM rather than whether it exists because the standard way to delete a node just detaches it from the DOM and relies on garbage collection to delete it from memory.