else { $builder->
scalarNode($name)->
defaultValue($default);
} } } /**
* @return string
*/
protected function createAuthenticationSuccessHandler(ContainerBuilder
$container, string
$id, array
$config) { $successHandlerId =
$this->
getSuccessHandlerId($id);
$options =
array_intersect_key($config,
$this->defaultSuccessHandlerOptions
);
if (isset($config['success_handler'
])) { $successHandler =
$container->
setDefinition($successHandlerId,
new ChildDefinition('security.authentication.custom_success_handler'
));
$successHandler->
replaceArgument(0,
new ChildDefinition($config['success_handler'
]));
$successHandler->
replaceArgument(1,
$options);
$successHandler->
replaceArgument(2,
$id);
} else { $successHandler =
$container->
setDefinition($successHandlerId,
new ChildDefinition('security.authentication.success_handler'
));
$successHandler->
addMethodCall('setOptions',
[$options]);
$successHandler->
addMethodCall('setFirewallName',
[$id]);
}