me-no-dev / ESPAsyncWebServer

Async Web Server for ESP8266 and ESP32
3.8k stars 1.23k forks source link

Change bool AsyncStaticWebHandler::canHandle to use exact match instead of String::startsWith(_uri) #1412

Open Zhu-jiatong opened 5 months ago

Zhu-jiatong commented 5 months ago

Change URL matching to use exact match instead of startsWith(_uri). This could improve the URL matching experience and enable he use of nested URLs, such as "/file" and "/file/add".

Change: !request->url().startsWith(_uri) -> request->url() != _uri