From f9b52003416a3cc1442f32ac00022b598082dfcd Mon Sep 17 00:00:00 2001 From: Oliver Scase Date: Tue, 3 Sep 2024 18:44:14 +0200 Subject: [PATCH] Fix: change method of removing trailing slash from url to support ios <17 --- src/runtime/utils/formatter.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/runtime/utils/formatter.ts b/src/runtime/utils/formatter.ts index 6afc5a4..af97bb7 100644 --- a/src/runtime/utils/formatter.ts +++ b/src/runtime/utils/formatter.ts @@ -1,3 +1,6 @@ export function trimTrailingSlash(path: string): string { - return path.replace(/(? 1 && path.slice(-1) === '/') { + return path.slice(0, -1); + } + return path; }