Provide relative urls in redirects and not absolute ones

Created on 11 March 2022, almost 3 years ago
Updated 12 August 2024, 4 months ago

Problem

Right now the redirect module is creating redirect responses that always include absolute urls but if there's an internal url why not make it relative.

Motivation

When using this as part of decoupled setup with lupus_ce_renderer module, we need to know whether the redirect is supposed to be to another internal url (=relative) or to some external other url (=absolute), so the frontend can correctly apply the redirect internally or externally.

Proposed resolution

Before creating the response check if the path is internal and pass a relative url to the response.

✨ Feature request
Status

Needs review

Version

1.0

Component

Code

Created by

πŸ‡·πŸ‡΄Romania ciprian.stavovei

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

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024