-
-
Notifications
You must be signed in to change notification settings - Fork 586
Fix multiple handler callbacks in YamlDriver #515
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix multiple handler callbacks in YamlDriver #515
Conversation
ping @schmittjoh Would be nice to see this merged, the fix is simple and obvious. If the new tests need some more work, I'll be happy to improve them. The test failures seem unrelated and are probably fixed by #511 in any case. |
0388346
to
b044dd0
Compare
Rebased, tests are now green as well. |
@@ -204,8 +204,8 @@ protected function loadMetadataFromFile(\ReflectionClass $class, $file) | |||
|
|||
if (isset($config['handler_callbacks'])) { | |||
foreach ($config['handler_callbacks'] as $direction => $formats) { | |||
$direction = GraphNavigator::parseDirection($direction); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as this store a different thing, it would be even better to use a different variable name instead of overwriting the variable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Loop variable name changed to $directionName
.
b044dd0
to
dcaf30a
Compare
will be part of v1.3, tnx |
Nice to see this merged finally, thanks. |
Using handler callbacks for multiple formats caused errors in
YamlDriver
because thedirection
key was parsed multiple times. Nowdirection
key is only parsed once (per direction).A basic test case for handler callbacks is included for all configuration formats.