Skip to content

[MSHARED-608] Remove index.html-adding block in AbstractMavenReportRenderer#getValidHref() #139

Description

@jira-importer

Michael Osipov opened MSHARED-608 and commented

If URL validation fails, the following is executed:

String hrefTmp;
if ( !href.endsWith( "/" ) )
{
  hrefTmp = href + "/index.html";
}
else
{
  hrefTmp = href + "index.html";
}

if ( UrlValidationUtil.isValidUrl( hrefTmp ) )
{
  return href;
}

There are several problems here:

  • The assumption that / will point to index.html is wrong. This is not known. It can ultimately lead to 404. No assumption shall be made to the target.
  • There is no way that if a URL is already invalid it will get a valid URL by adding index.html.

Remove this code block.


Affects: maven-reporting-impl 2.4

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingpriority:majorMajor loss of function

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions