Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

PathPatternRequestMatcherBuilder should not create a double-slash URI with a root base path #17812

Open
Labels
in: webAn issue in web modules (web, webmvc) status: ideal-for-contributionAn issue that we actively are looking for someone to help us with type: bugA general bug
Milestone
@jzheaux

Description

When using

PathPatternRequestMatcher.withDefaults().basePath("/").pattern("/my-pattern");

The result is a pattern of //my-pattern. The logic in pattern should be able to deal with root base paths without creating a double-slash. Instead the result should be /my-pattern.

Let's consider changing the default base path to /. Then the logic can instead be:

String prefix = ("/".equals(this.basePath)) ? "" : this.basePath;
PathPattern pathPattern = this.parser.parse(prefix + path);
// ...

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: webAn issue in web modules (web, webmvc) status: ideal-for-contributionAn issue that we actively are looking for someone to help us with type: bugA general bug

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      AltStyle によって変換されたページ (->オリジナル) /