Skip to content

Commit a12e143

Browse files
Merge branch '3.4'
* 3.4: [HttpKernel] Disable container inlining when legacy inlining has been used Let getFlashes starts the session Update default translations path [FrameworkBundle] Ignore failures when removing the old cache dir
2 parents 3a8377a + 369cbb9 commit a12e143

File tree

6 files changed

+10
-5
lines changed

6 files changed

+10
-5
lines changed

Command/CacheClearCommand.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
use Symfony\Component\Console\Output\OutputInterface;
1818
use Symfony\Component\Console\Style\SymfonyStyle;
1919
use Symfony\Component\EventDispatcher\EventDispatcher;
20+
use Symfony\Component\Filesystem\Exception\IOException;
2021
use Symfony\Component\Filesystem\Filesystem;
2122
use Symfony\Component\HttpKernel\CacheClearer\CacheClearerInterface;
2223
use Symfony\Component\HttpKernel\RebootableInterface;
@@ -104,7 +105,11 @@ protected function execute(InputInterface $input, OutputInterface $output)
104105
$io->comment('Removing old cache directory...');
105106
}
106107

107-
$this->filesystem->remove($oldCacheDir);
108+
try {
109+
$this->filesystem->remove($oldCacheDir);
110+
} catch (IOException $e) {
111+
$io->warning($e->getMessage());
112+
}
108113

109114
if ($output->isVerbose()) {
110115
$io->comment('Finished');

DependencyInjection/Configuration.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -626,7 +626,7 @@ private function addTranslatorSection(ArrayNodeDefinition $rootNode)
626626
->scalarNode('formatter')->defaultValue('translator.formatter.default')->end()
627627
->scalarNode('default_path')
628628
->info('The default path used to load translations')
629-
->defaultValue('%kernel.project_dir%/config/translations')
629+
->defaultValue('%kernel.project_dir%/translations')
630630
->end()
631631
->arrayNode('paths')
632632
->prototype('scalar')->end()

Tests/DependencyInjection/ConfigurationTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ protected static function getBundleDefaultConfig()
155155
'logging' => true,
156156
'formatter' => 'translator.formatter.default',
157157
'paths' => array(),
158-
'default_path' => '%kernel.project_dir%/config/translations',
158+
'default_path' => '%kernel.project_dir%/translations',
159159
),
160160
'validation' => array(
161161
'enabled' => !class_exists(FullStack::class),

Tests/DependencyInjection/Fixtures/yml/full.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ framework:
4242
translator:
4343
enabled: true
4444
fallback: fr
45-
default_path: '%kernel.root_dir%/config/translations'
45+
default_path: '%kernel.root_dir%/translations'
4646
paths: ['%kernel.root_dir%/Fixtures/translations']
4747
validation:
4848
enabled: true

Tests/DependencyInjection/FrameworkExtensionTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -496,7 +496,7 @@ public function testTranslator()
496496
'->registerTranslatorConfiguration() finds translation resources in custom paths'
497497
);
498498
$this->assertContains(
499-
strtr(__DIR__.'/config/translations/test_default.en.xlf', '/', DIRECTORY_SEPARATOR),
499+
strtr(__DIR__.'/translations/test_default.en.xlf', '/', DIRECTORY_SEPARATOR),
500500
$files,
501501
'->registerTranslatorConfiguration() finds translation resources in default path'
502502
);

0 commit comments

Comments
 (0)