drive-s3 icon indicating copy to clipboard operation
drive-s3 copied to clipboard

Potential URL Concatenation Issue in getUrl Method

Open martinholecekmax opened this issue 1 year ago • 1 comments

https://github.com/adonisjs/drive-s3/blob/96f2727730baff2f47bfc7cce8001b3563d75528/src/Drivers/S3.ts#L339

There appears to be a potential issue in the getUrl method of the S3Driver class. The method concatenates this.cachedBucketUrl and location directly without a slash in between, potentially leading to malformed URLs.

martinholecekmax avatar Jan 14 '24 19:01 martinholecekmax

Hey @martinholecekmax! 👋🏻

I believe we could use the URL class to properly append the path. Do you want to make a PR?

RomainLanz avatar Feb 15 '24 11:02 RomainLanz