Support Redirect 404

Created on 14 December 2023, 7 months ago
Updated 10 April 2024, 3 months ago

Problem/Motivation

There is submodule to Redirect, called Redirect 404, which logs all the 404 pages. If Fast 404 module is enabled, then it doesn't work.

Steps to reproduce

Enable Fast 404, Redirect. If you visit non existent page, it shows 404 page, but doesn't log it for Redirect 404.

Proposed resolution

Currently Redirect listens to
$events[KernelEvents::EXCEPTION][] = 'onKernelException';
but the way fast 404 works, is that intercepts that by having a higher priority. I suggest to listed to the response instead of kernel exception:

$events[KernelEvents::RESPONSE][] = 'onResponse';
....
if ($event->getResponse()->getStatusCode() === Response::HTTP_NOT_FOUND) {
โœจ Feature request
Status

Needs review

Version

1.0

Component

Code

Created by

๐Ÿ‡ฐ๐Ÿ‡ฌKyrgyzstan elaman

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.69.0 2024