Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[EventDispatcher] Correct the called event listener method case#41905
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -81,7 +81,7 @@ public function process(ContainerBuilder $container) | ||
| if (!isset($event['method'])) { | ||
| $event['method'] = 'on'.preg_replace_callback([ | ||
| '/(?<=\b|_)[a-z]/i', | ||
| '/[^a-z0-9]/i', | ||
Contributor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. btw this 2nd regex is a leftover fromhttps://github.com/symfony/symfony/pull/1162/files it seems, where it was replaced with empty string which now happens at L87, this happened with refactoring likely. AFAIK it's redundant 👼 ContributorAuthor There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. it confused me too, but I'm not sure we can remove | ||
| ], function ($matches) { return strtoupper($matches[0]); }, $event['event']); | ||
| $event['method'] = preg_replace('/[^a-z0-9]/i', '', $event['method']); | ||