b13 / slimphp-bridge

SlimPHP Integration in TYPO3 Frontend for rapid API development
GNU General Public License v2.0
18 stars 5 forks source link

SlimInitiator processes routes not meant for it #5

Closed saneinsane closed 2 years ago

saneinsane commented 3 years ago

In the readme it is stated that "The prefix value enables a SlimPHP Application", but in https://github.com/b13/slimphp-bridge/blob/3147852ed50c855269ba639bbfe3569fa91cff92/src/Middleware/SlimInitiator.php#L59 prefix gets a default value. So if you have an additional route (like a static route for robots.txt), SlimInitiator will try to init a Slim Route which leads to route status RoutingResults::NOT_FOUND.

saneinsane commented 3 years ago

I just found that this issue was already posted and closed (#2). For me it’s still existing – I have to add a nonsense prefix to robots.txt node so that slimphpbridge does not try to process it. (TYPO3 10.4.12, slim bridge 0.1.0)