Wrong route retrieved
orel91 opened this issue · comments
Aurelien commented
Hello,
When I create 2 routes in this order:
server.AddGetRoute("/", new SampleMiddleWare());
server.AddTransparentFolderRoute("/style", storageFolder);
and try to access to a file in the second route with the url '/style/style.css', I always get the content of the first route.
However, if I write these 2 lines in this order:
server.AddTransparentFolderRoute("/style", storageFolder);
server.AddGetRoute("/", new SampleMiddleWare());
everything seems to work fine.
Is this a bug or am I using it wrong ?
For information, the bug seems to be located in the FilterMiddlewares method of the MiddlewareManager class.
Kind Regards,
Aurelien
Valentin Michalak commented
Hi orel91,
Thanks you for your feedback, it's really a bug in hermes.net.
I correct it in the new build, you can download it directly on NuGet if you want.
Kind Regards,
Valentin Michalak