You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Rename remove() to remove_at() when removing by index
This commit is contained in:
committed by
Aaron Record
parent
5efe80f308
commit
e078f970db
@@ -3670,15 +3670,15 @@ String String::simplify_path() const {
|
||||
for (int i = 0; i < dirs.size(); i++) {
|
||||
String d = dirs[i];
|
||||
if (d == ".") {
|
||||
dirs.remove(i);
|
||||
dirs.remove_at(i);
|
||||
i--;
|
||||
} else if (d == "..") {
|
||||
if (i == 0) {
|
||||
dirs.remove(i);
|
||||
dirs.remove_at(i);
|
||||
i--;
|
||||
} else {
|
||||
dirs.remove(i);
|
||||
dirs.remove(i - 1);
|
||||
dirs.remove_at(i);
|
||||
dirs.remove_at(i - 1);
|
||||
i -= 2;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user