Code Duplication    Length = 7-7 lines in 2 locations

lib/Service/FileService.php 2 locations

@@ 230-236 (lines=7) @@
227
			$filePath = substr_replace ( $filePath, '', $pos, strlen ( '/' ) ); // '/' => '' || '/Test/' => 'Test'
228
		}
229
		
230
		if ($fileInfo->getMimetype () === OcrConstants::MIME_TYPE_PDF) {
231
			// PDFs:
232
			return $this->buildNotExistingFilename ( $filePath, $fileName . '_OCR.pdf' );
233
		} else {
234
			// IMAGES:
235
			return $this->buildNotExistingFilename ( $filePath, $fileName . '_OCR.txt' );
236
		}
237
	}
238
	
239
	/**
@@ 268-274 (lines=7) @@
265
			$filePath = substr_replace ( $filePath, '', $pos, strlen ( '/' ) ); // '/Test' => '// 'Test' || '/' => ''
266
		}
267
		
268
		if ($fileInfo->getMimetype () === OcrConstants::MIME_TYPE_PDF) {
269
			// PDFs:
270
			return $this->buildNotExistingFilename ( $filePath, $fileName . '_OCR.pdf' );
271
		} else {
272
			// IMAGES:
273
			return $this->buildNotExistingFilename ( $filePath, $fileName . '_OCR.txt' );
274
		}
275
	}
276
	
277
	/**