Errors when trying to delete DOM elements #1492

brukhabtu opened this Issue Apr 20, 2011 · 3 comments


None yet

2 participants


I have some elements I am adding and deleting and I occasionally get this error. The library I am using is not my own and can be found .

Uncaught TypeError: Cannot set property 'vmouseover' of undefined

I have found a fix for this but since I know nearly nothing about jquery mobile's inner workings it may break things more. Here is the fix.

bindings[eventType] = false; // line 867

if (bindings != undefined) {bindings[eventType] = false;}

If someone who understands the code a bit more can assure me that this doesn't break anything in the long run i will request for a pull.

jblas commented Apr 20, 2011

Hi @brukhabtu,

We could certainly check an undefined bindings data value. I just want to confirm with some folks in the know if stripping of element data before teardown is called, is expected behavior. It seems like stripping of data should happen AFTER just in case the special event needed something in the data to aid with cleanup.

@jblas jblas was assigned Apr 20, 2011
jblas commented Apr 21, 2011


I landed your fix with some additional comments and gave you credit.


Thanks for finding, filing, and fixing. :-)

  • Kin
@jblas jblas closed this Apr 21, 2011

Thanks, glad to be of some help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment