Tree: set isCurrent prop to False (#15870)

pull/16398/head
huming 2019-07-04 11:30:02 +08:00 committed by hetech
parent 64557d4aeb
commit 905e812fb5
1 changed files with 2 additions and 2 deletions

View File

@ -327,8 +327,8 @@ export default class TreeStore {
}
setCurrentNodeKey(key) {
if (key === null) {
this.currentNode.isCurrent = false;
if (key === null || key === undefined) {
this.currentNode && (this.currentNode.isCurrent = false);
this.currentNode = null;
return;
}