Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

Uncaught TypeError on dropdown element click. #2343

Closed
aleclofabbro opened this issue Jun 15, 2014 · 5 comments
Closed

Uncaught TypeError on dropdown element click. #2343

aleclofabbro opened this issue Jun 15, 2014 · 5 comments

Comments

@aleclofabbro
Copy link

I couldn't dig it too much but:
when opening a dropdown, and clicking a child-element,
this function
https://github.com/angular-ui/bootstrap/blob/master/src/dropdown/dropdown.js#L23
is invoked and sets openscope to null,
subsequently, this function is invoked
https://github.com/angular-ui/bootstrap/blob/master/src/dropdown/dropdown.js#L31
openscope is null there, and i get an Uncaught TypeError: Cannot read property 'getToggleElement' of null

@pkozlowski-opensource
Copy link
Member

Sorry, there is not enough details to help you. If you need assistance prepare a reproduce scenario using http://plnkr.co/

@aleclofabbro
Copy link
Author

I'm very sorry, i can't reproduce it with a simple plunk,
but copying my original modules and views in plunker the error shows up!
http://plnkr.co/edit/no8CRfEFeWAT6XLsYW6W [edit : <- this is a mess try the next comment's]

on nav-bar click Utenti->ricerca a couple of times

** this must be a very particular situation.. it seems that the error shows only if i load the ui.dropdown.js separately.

@aleclofabbro
Copy link
Author

check this plunk instead, it's veeery simple now:
http://plnkr.co/edit/QINTHFCGDVaq37puGPyq
on nav-bar click Utenti->ricerca

@dnezic
Copy link

dnezic commented Sep 30, 2014

I have exactly the same problem since upgrading from 0.11.0 to 0.11.2.

@chrisirhc
Copy link
Contributor

Thanks for reporting this issue. Fixed on master.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants