1
0
Fork 0
pull/5738/head
Yanick Witschi 2016-09-30 17:40:28 +02:00
parent 4a769a785c
commit a9e88a27b3
1 changed files with 2 additions and 2 deletions

View File

@ -58,12 +58,12 @@ class RuleSet implements \IteratorAggregate, \Countable
throw new \OutOfBoundsException('Unknown rule type: ' . $type);
}
$hash = $rule->getHash();
if (!isset($this->rules[$type])) {
$this->rules[$type] = array();
}
$hash = $rule->getHash();
// Do not add if rule already exists
if (isset($this->rulesByHash[$hash])) {
$potentialDuplicates = $this->rulesByHash[$hash];