Ver código fonte

EAGLESIX-2653: Add tag cloning to shallowClone

Chris Sexton 11 anos atrás
pai
commit
86c6048275
1 arquivos alterados com 2 adições e 0 exclusões
  1. 2 0
      lib/pipeline/matcher/ExistsMatchExpression.js

+ 2 - 0
lib/pipeline/matcher/ExistsMatchExpression.js

@@ -71,6 +71,8 @@ proto.matchesSingleElement = function matchesSingleElement(e) {
 proto.shallowClone = function shallowClone(){
 	var e = new ExistsMatchExpression();
 	e.init(this.path());
+	if (this.getTag())
+		e.setTag(this.getTag().clone());
 	return e;
 };