You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To my eye, it looks like the removeEventListeners in destroy are incorrect. Here.
(AFAIU):
The result of owner.onChange.bind(owner) is a new function, hence the removal is trying to remove a "different" function to the one that's attached, and hence not removing anything. Instead the result of the bind could be stored as a variable so that the exact save function is passed to removeEventListener, and hence is removed correctly.
(Apologies if I'm being silly :-) (I haven't actually tried the library, I just noticed it... It looks neat though, awesome work, and I love the idea :-) ))
The text was updated successfully, but these errors were encountered:
To my eye, it looks like the
removeEventListener
s indestroy
are incorrect. Here.(AFAIU):
The result of
owner.onChange.bind(owner)
is a new function, hence the removal is trying to remove a "different" function to the one that's attached, and hence not removing anything. Instead the result of thebind
could be stored as a variable so that the exact save function is passed toremoveEventListener
, and hence is removed correctly.To try and demonstrate:
vs
(Apologies if I'm being silly :-) (I haven't actually tried the library, I just noticed it... It looks neat though, awesome work, and I love the idea :-) ))
The text was updated successfully, but these errors were encountered: