Skip to content
This repository was archived by the owner on Nov 25, 2020. It is now read-only.

Commit 5337361

Browse files
committed
Fix isUnique() function in datamodel.
1 parent 4877ba3 commit 5337361

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

core/src/plugins/gui.ajax/res/js/es6/model/PydioDataModel.es6

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ class PydioDataModel extends Observable{
3434
this._bEmpty = true;
3535
this._globalEvents = !localEvents;
3636

37-
this._bUnique= false;
3837
this._bFile= false;
3938
this._bDir= false;
4039
this._isRecycle= false;
@@ -460,10 +459,8 @@ class PydioDataModel extends Observable{
460459
this._selectedNodes = ajxpDataNodes;
461460
this._bEmpty = ((ajxpDataNodes && ajxpDataNodes.length)?false:true);
462461
this._bFile = this._bDir = this._isRecycle = false;
463-
this._bUnique = false;
464462
if(!this._bEmpty)
465463
{
466-
this._bUnique = (ajxpDataNodes.length == 1);
467464
for(var i=0; i<ajxpDataNodes.length; i++)
468465
{
469466
var selectedNode = ajxpDataNodes[i];
@@ -555,7 +552,7 @@ class PydioDataModel extends Observable{
555552
* @returns Boolean
556553
*/
557554
isUnique (){
558-
return this._bUnique;
555+
return this._selectedNodes && this._selectedNodes.length === 1;
559556
}
560557

561558
/**

0 commit comments

Comments
 (0)