Code Duplication    Length = 7-7 lines in 2 locations

src/Experiment.php 2 locations

@@ 87-93 (lines=7) @@
84
            }
85
        }
86
87
        if (isset($config['storage']) && $config['storage'] instanceof StorageInterface) {
88
            $this->storage = $config['storage'];
89
        } elseif (isset($config['storage'])) {
90
            throw new InvalidArgumentException('storage needs to be an instance of StorageInterface');
91
        } else {
92
            $this->storage = new Cookie();
93
        }
94
95
        if (isset($config['filter']) && $config['filter'] instanceof FilterInterface) {
96
            $this->filter = $config['filter'];
@@ 95-101 (lines=7) @@
92
            $this->storage = new Cookie();
93
        }
94
95
        if (isset($config['filter']) && $config['filter'] instanceof FilterInterface) {
96
            $this->filter = $config['filter'];
97
        } elseif (isset($config['filter'])) {
98
            throw new InvalidArgumentException('filter config needs to be an instance of FilterInterface');
99
        } else {
100
            $this->filter = new DefaultFilters($this->name, $this->storage, $config);
101
        }
102
    }
103
104
    /**