From: Eduardo San Martin Morote Date: Thu, 6 Aug 2020 13:30:14 +0000 (+0200) Subject: chore: add comment [skip ci] X-Git-Tag: v4.0.0-beta.7~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3896f15668672d9eca2f1bc56e3b8383586a3770;p=thirdparty%2Fvuejs%2Frouter.git chore: add comment [skip ci] --- diff --git a/src/matcher/pathParserRanker.ts b/src/matcher/pathParserRanker.ts index fad25118..6910e3ac 100644 --- a/src/matcher/pathParserRanker.ts +++ b/src/matcher/pathParserRanker.ts @@ -235,7 +235,7 @@ export function tokensToParser( const text: string = Array.isArray(param) ? param.join('/') : param if (!text) { if (optional) { - // remove the last slash + // remove the last slash as we could be at the end if (path.endsWith('/')) path = path.slice(0, -1) // do not append a slash on the next iteration else avoidDuplicatedSlash = true