Skip to content

Adding double slashes to external domains in an IMG_MAP #398

@UpTEN

Description

@UpTEN

I'm using a multipath img_map and wanted to upgrade to the latest version. Unfortunately, it now tries to access invalid remote URLs because it adds additional slashes.

Everything still works in version 0.12.3.

To Reproduce
When you add an IMG_MAP like this:
"IMG_MAP": { "/img": "./orig", "/img2": "https://s3.wasabisys.com/abc" },

It tries to fetch an image from the URL https://s3.wasabisys.com//abc - with a double slash.
And if I remember correct, if you configure the IMG_MAP like this:
"/img2": "https://abc.s3.wasabisys.com"
it showed some really odd behavior. When it should fetch an image from 'https://abc.s3.wasabisys.com/images/uploads/123.jpg' it tried to fetch it from 'https://abc.s3.wasabisys.com/images//uploads/123.jpg' instead.

However, it's a great piece of work that you did and I really enjoy using it.
Thank you very much!

Alex

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions