PHP-DI / Slim-Bridge

PHP-DI integration with the Slim framework
http://php-di.org/doc/frameworks/slim.html
MIT License
176 stars 38 forks source link

Allow attributes to not override #90

Open andrewnicols opened 2 months ago

andrewnicols commented 2 months ago

Based on #89

This allows for configuration of the placeholder overiding an attribute behaviour as discussed in #86.

If there's a more appropriate way to handle this configuration, I'm happy to change it. I don't find the current approach very elegant but I can't see a better way right now (though it is nearly 1am).

It's worth noting that this change does not change the parameter value to be the attribute, it merely stops the attribute from being overwritten by the placeholder value if a value is already set.