On Fri Jan 6 16:47:36 2023 +0000, Gabriel Ivăncescu wrote:
Rather than cast, the correct way is to QueryInterface for it. :)
Also, use `nsAString_InitDepend` instead of nsAString_Init; it basically makes it depend on the source (reference it), instead of copying it, and well the source is a constant string so it's always available.
And there is no reason to check for nsnode (`This->node.nsnode`), it should never be NULL. It does get NULL when it's unlinked, but unlinked means that nothing else references it, so if it ends up here it's a (refcount) bug somewhere.