From cee66600aeb1d6c035ca5748ab8a9e69ab75965b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elodie=20Thi=C3=A9blin?= Date: Tue, 27 Jul 2021 10:44:47 +0200 Subject: [PATCH] fix: consider last path fragment as a directory --- lib/url.js | 1 - 1 file changed, 1 deletion(-) diff --git a/lib/url.js b/lib/url.js index 7855f693..63bc267c 100644 --- a/lib/url.js +++ b/lib/url.js @@ -106,7 +106,6 @@ api.prependBase = (base, iri) => { let path = base.path; // append relative path to the end of the last directory from base - path = path.substr(0, path.lastIndexOf('/') + 1); if((path.length > 0 || base.authority) && path.substr(-1) !== '/') { path += '/'; }