herd-community
herd-community copied to clipboard
[Bug]: 301 redirect on missing image
Platform
macOS
Operating system version
macOs Sonoma 14.2.1 (23C71)
System architecture
ARM64 (M1, M2, etc)
Herd Version
1.6.1 (Build: 25) Pro
PHP Version
PHP 8.3+
Bug description
When you load an asset in the code, such as an image that is missing from the path, Nginx will attempt to open the image and then get redirected to the home page URL, resulting in another request. This could be problematic if you have numerous images, as it may slow down your setup.
This is not how it works in regular setups. If you receive a missing path, it should return a 404 error instead of redirecting the request.
Steps to reproduce
- Create and image tag in HTML
- Add some missing path to src
- Open Inspector and see two requests, one for the image > 301 and one for the home page.an
Relevant log output
No response