Skip to content

[3.2][fix] Return proper 404 for missing favicon.ico, missing images etc. #530

@vbmark

Description

@vbmark

I set a breakpoint in libs\Application.php in __construct() and found it was getting hit twice.

The second hit is a get of favicon.ico and it was not found so it looks like there is a behind-the-scenes redirect to the error page happening. However, there is no visual effect on the rendered page view.

This seems like extra and unnecessary work going on.

What I did was under this line:

if ($this->url_controller) {

I added this:

if ($this->url_controller == 'favicon.ico') {
return;
}

I don't know if that's the best way but it seems to be working for me.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions