Fix repeatedly adding relations with shift-R
authorRichard Fairhurst <richard@systemeD.net>
Fri, 24 Mar 2017 14:08:50 +0000 (14:08 +0000)
committerRichard Fairhurst <richard@systemeD.net>
Fri, 24 Mar 2017 14:08:50 +0000 (14:08 +0000)
net/systemeD/potlatch2/controller/ControllerState.as

index bf3c5e3..7d6d6b2 100644 (file)
@@ -228,7 +228,7 @@ package net.systemeD.potlatch2.controller {
                        var undo:CompositeUndoableAction = new CompositeUndoableAction("Repeat relations");
                        var relationsadded:uint;
                        for each (var rr:Object in controller.relationClipboards[object.getType()]) {
-                               if (!rr.relation.findEntityMemberIndex(object)>-1) {
+                               if (rr.relation.findEntityMemberIndex(object)==-1) {
                                        rr.relation.appendMember(new RelationMember(object, rr.role), undo.push);
                                        relationsadded++;
                                }