refactor: Replace deprecated substr with substring (#8644)

This commit is contained in:
Corey
2023-06-20 06:07:10 -04:00
committed by GitHub
parent 9674d4a2c0
commit 3710da7379
4 changed files with 32 additions and 57 deletions

View File

@@ -25,7 +25,7 @@ function removeTrailingSlash(str) {
return str;
}
if (str.endsWith('/')) {
str = str.substr(0, str.length - 1);
str = str.substring(0, str.length - 1);
}
return str;
}