@@ -426,7 +426,7 @@ Especially when storing many paths, the amount of duplicated information is
426426noticeable. You can use :method: `Symfony\\ Component\\ Filesystem\\ Path::getLongestCommonBasePath `
427427to check a list of paths for a common base path::
428428
429- Path::getLongestCommonBasePath(
429+ $basePath = Path::getLongestCommonBasePath(
430430 '/var/www/vhosts/project/httpdocs/config/config.yaml',
431431 '/var/www/vhosts/project/httpdocs/config/routing.yaml',
432432 '/var/www/vhosts/project/httpdocs/config/services.yaml',
@@ -435,17 +435,14 @@ to check a list of paths for a common base path::
435435 );
436436 // => /var/www/vhosts/project/httpdocs
437437
438- Use this path together with :method: `Symfony\\ Component\\ Filesystem\\ Path::makeRelative `
439- to shorten the stored paths::
440-
441- $bp = '/var/www/vhosts/project/httpdocs';
438+ Use this common base path to shorten the stored paths::
442439
443440 return [
444- $bp .'/config/config.yaml',
445- $bp .'/config/routing.yaml',
446- $bp .'/config/services.yaml',
447- $bp .'/images/banana.gif',
448- $bp .'/uploads/images/nicer-banana.gif',
441+ $basePath .'/config/config.yaml',
442+ $basePath .'/config/routing.yaml',
443+ $basePath .'/config/services.yaml',
444+ $basePath .'/images/banana.gif',
445+ $basePath .'/uploads/images/nicer-banana.gif',
449446 ];
450447
451448:method: `Symfony\\ Component\\ Filesystem\\ Path::getLongestCommonBasePath ` always
0 commit comments