diff options
author | lou <louiscuny@gmail.com> | 2014-05-21 10:37:14 +0200 |
---|---|---|
committer | lou <louiscuny@gmail.com> | 2014-05-21 10:37:14 +0200 |
commit | d7c375e24993d3e3dded70b297aedb22994cec01 (patch) | |
tree | 2d0d3968c34f9d583d2163963e272995710b0fa8 /js/jquery.multi-select.js | |
parent | a582b049b7010b7ed514e3d531248ccb1747a7df (diff) | |
download | multi-select-d7c375e24993d3e3dded70b297aedb22994cec01.zip multi-select-d7c375e24993d3e3dded70b297aedb22994cec01.tar.gz multi-select-d7c375e24993d3e3dded70b297aedb22994cec01.tar.bz2 |
fix options order in optgroup (fix #133)
Diffstat (limited to 'js/jquery.multi-select.js')
-rw-r--r-- | js/jquery.multi-select.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/jquery.multi-select.js b/js/jquery.multi-select.js index dfc92db..08a2e06 100644 --- a/js/jquery.multi-select.js +++ b/js/jquery.multi-select.js @@ -160,7 +160,7 @@ that.$selectableUl.append($selectableOptgroup); that.$selectionUl.append($selectionOptgroup); } - index = index == undefined ? $selectableOptgroup.children().length : index + 1; + index = index == undefined ? $selectableOptgroup.find('ul').children().length : index + 1; selectableLi.insertAt(index, $selectableOptgroup.children()); selectedLi.insertAt(index, $selectionOptgroup.children()); } else { |