mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Fix character getter API usage in stripLeftSlashes/stripRightSlashes (flutter/engine#53299)
This commit is contained in:
parent
f1978535f0
commit
593a9d0da5
@ -22,7 +22,7 @@ export function joinPathSegments(...segments) {
|
||||
function stripLeftSlashes(s) {
|
||||
let i = 0;
|
||||
while (i < s.length) {
|
||||
if (s.charCodeAt(i) !== "/") {
|
||||
if (s.charAt(i) !== "/") {
|
||||
break;
|
||||
}
|
||||
i++;
|
||||
@ -33,7 +33,7 @@ function stripLeftSlashes(s) {
|
||||
function stripRightSlashes(s) {
|
||||
let i = s.length;
|
||||
while (i > 0) {
|
||||
if (s.charCodeAt(i - 1) !== "/") {
|
||||
if (s.charAt(i - 1) !== "/") {
|
||||
break;
|
||||
}
|
||||
i--;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user