Code Duplication    Length = 10-10 lines in 2 locations

src/Subjects/BunchSubject.php 2 locations

@@ 205-214 (lines=10) @@
202
        }
203
204
        // initialize media directory => can be absolute or relative
205
        if ($this->getConfiguration()->hasParam(FileUploadConfigurationKeys::MEDIA_DIRECTORY)) {
206
            try {
207
                $this->setMediaDir($this->resolvePath($this->getConfiguration()->getParam(FileUploadConfigurationKeys::MEDIA_DIRECTORY)));
208
            } catch (\InvalidArgumentException $iae) {
209
                // only if we wanna copy images we need directories
210
                if ($this->hasCopyImages()) {
211
                    $this->getSystemLogger()->warning($iae->getMessage());
212
                }
213
            }
214
        }
215
216
        // initialize images directory => can be absolute or relative
217
        if ($this->getConfiguration()->hasParam(FileUploadConfigurationKeys::IMAGES_FILE_DIRECTORY)) {
@@ 217-226 (lines=10) @@
214
        }
215
216
        // initialize images directory => can be absolute or relative
217
        if ($this->getConfiguration()->hasParam(FileUploadConfigurationKeys::IMAGES_FILE_DIRECTORY)) {
218
            try {
219
                $this->setImagesFileDir($this->resolvePath($this->getConfiguration()->getParam(FileUploadConfigurationKeys::IMAGES_FILE_DIRECTORY)));
220
            } catch (\InvalidArgumentException $iae) {
221
                // only if we wanna copy images we need directories
222
                if ($this->hasCopyImages()) {
223
                    $this->getSystemLogger()->warning($iae->getMessage());
224
                }
225
            }
226
        }
227
228
        // invoke the parent method
229
        parent::setUp($serial);