Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory Leak #578

Closed
KpjComp opened this issue Apr 29, 2014 · 1 comment
Closed

Memory Leak #578

KpjComp opened this issue Apr 29, 2014 · 1 comment

Comments

@KpjComp
Copy link

KpjComp commented Apr 29, 2014

Hi,

I'm currently using bootstrap-select in an ajax page loading type website. I believe I've spotted a memory leak, after a while it also crashes chrome.

In the clickListener function you are doing this ->

$('body').on('touchstart.dropdown', '.dropdown-menu', function(e) {
                e.stopPropagation();
            }); 

This then gets called on every init, and will never remove the event from the body.
IOW: if you have a hundred Selects you will have 100 touchstart.dropdown events.

Placing this code were you have put your $(document).on('keydown') and .on('focusin.modal') seems to fix the problem..

Regards

Keith..

@t0xicCode
Copy link
Collaborator

This was fixed in an earlier commit.

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

No branches or pull requests

2 participants