8000 Support use of hyphen in asset package name · XuruDragon/symfony@2cefc0c · GitHub
[go: up one dir, main page]

Skip to content

Commit 2cefc0c

Browse files
damayaAnthony MARTIN
authored and
Anthony MARTIN
committed
Support use of hyphen in asset package name
| Q | A | ------------- | --- | Branch? | master | Bug fix? | yes | New feature? | no | BC breaks? | no <!-- see https://symfony.com/bc --> | Deprecations? | no | Tests pass? | yes (Manual tests only) | Fixed tickets | symfony#28122 | License | MIT | Doc PR | n/a According to issue symfony/symfony-docs#10442, we tested in a demo bundle, for example in src/AppBundle/Resources/config/config.yml a package using hyphens: app-client-frontend, and withouth the patch it fails because the package is not recognized. With the patch, it works as expected. ``` framework: assets: packages: app-client-frontend: version: "%env(FRONTEND_VERSION)%" version_format: '%%2$s/dist/%%1$s' base_urls: - "%env(FRONTEND_URL)%" ```
1 parent 140a07f commit 2cefc0c

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/Symfony/Bundle/FrameworkBundle/DependencyInjection/Configuration.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -648,6 +648,7 @@ private function addAssetsSection(ArrayNodeDefinition $rootNode)
648648
->fixXmlConfig('package')
649649
->children()
650650
->arrayNode('packages')
651+
->normalizeKeys(false)
651652
->useAttributeAsKey('name')
652653
->prototype('array')
653654
->fixXmlConfig('base_url')

0 commit comments

Comments
 (0)
0