Open dantleech opened 9 years ago
Do you think there are going to be more settings than the HTTP code? Otherwise, I'd prefer to not use the options resolver and just pass a config value to the constructor of LeaveRedirectDefunctRouteHandler
.
There was a reason -- iirc it might have been that the HTTP code is not a DI config, is is metadata.
I propose to remove the ConfigurableInterface and add a new BC break. However, the current PR doesn't do anything, as the http code option isn't used anywhere in the code.
The aim of this POC PR is to explore the possiblity passing options to the defunct route handlers - the use case being allowing the redirect HTTP code to be passed to the adapter which creates the redirect route.
Intitially I tried to avoid BC breaks, but the requirement to add
$options
to thehandleDefunctRoutes
method breaks any chance of this. The role of the newConfigurableInterface
is therefore up for debate.