vakata/jstree — Issue #155: removed node appear in get_selected() after a refresh
Author: nmss
Created: 2011-12-22 15:29:23+00:00
State: open

to reproduce:

```javascript
$('#tree').jstree({
plugins : ["themes", "ui", "json_data"],
core : {
'animation' : false
},
themes : {
"dots" : false
},
json_data : {
data : [{
"data" : "1",
"attr" : {
"id" : "1"
},
"children" : [{
"data" : "2",
"attr" : {
"id" : "2"
}
}]
}]
},
});
$('#tree').on('loaded.jstree', function(){
$('#tree').jstree('open_all');
$('#tree').jstree('select_node', '#2');
console.log($('#tree').jstree('get_selected'));
$('#tree').jstree('refresh');
console.log($('#tree').jstree('get_selected'));
})
```
the second log line is:
`[
​…​
​,
​…​
​]`
the first
is from the tree
the second is from before the refresh, but now is deteched from DOM