You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Eric Norman (Jira)" <ji...@apache.org> on 2022/05/29 21:40:00 UTC

[jira] [Created] (SLING-11347) SlingUriBuilder.createFrom(request) should preserve any mapped resource path

Eric Norman created SLING-11347:
-----------------------------------

             Summary: SlingUriBuilder.createFrom(request) should preserve any mapped resource path
                 Key: SLING-11347
                 URL: https://issues.apache.org/jira/browse/SLING-11347
             Project: Sling
          Issue Type: Bug
            Reporter: Eric Norman
            Assignee: Eric Norman
             Fix For: API 2.25.2


Use Case:

Use the SlingUriBuilder.createFrom(request) call from a servlet in order to create a SlingUri from the current request in order to change the selectors (or extension) and then redirect to that new uri value.

Expected:

When calling SlingUriBuilder.createFrom(request) for a mapped request path, the built SlingUri object should return the original mapped path from the getResourcePath() call instead of the resource path that was resolved from the mapped path.

This should help to avoid accidentally switching from /folder/page1 to /content/folder/page1 in the SlingUri output.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)