Code Duplication    Length = 10-10 lines in 3 locations

src/Charcoal/Loader/FileLoader.php 2 locations

@@ 319-328 (lines=10) @@
316
     * @throws InvalidArgumentException If the path does not exist or is invalid.
317
     * @return self
318
     */
319
    public function addPath($path)
320
    {
321
        $path = $this->resolvePath($path);
322
323
        if ($path && $this->validatePath($path)) {
324
            $this->paths[] = $path;
325
        }
326
327
        return $this;
328
    }
329
330
    /**
331
     * Prepend a path.
@@ 336-345 (lines=10) @@
333
     * @param  string $path A file or directory path.
334
     * @return self
335
     */
336
    public function prependPath($path)
337
    {
338
        $path = $this->resolvePath($path);
339
340
        if ($path && $this->validatePath($path)) {
341
            array_unshift($this->paths, $path);
342
        }
343
344
        return $this;
345
    }
346
347
    /**
348
     * Parse a relative path using the base path if needed.

src/Charcoal/Model/Service/MetadataLoader.php 1 location

@@ 294-303 (lines=10) @@
291
     * @throws InvalidArgumentException If the path does not exist or is invalid.
292
     * @return self
293
     */
294
    private function addPath($path)
295
    {
296
        $path = $this->resolvePath($path);
297
298
        if ($this->validatePath($path)) {
299
            $this->paths[] = $path;
300
        }
301
302
        return $this;
303
    }
304
305
    /**
306
     * Parse a relative path using the base path if needed.