Use get_slicec instead of get_slice for single character splitters

This commit is contained in:
A Thousand Ships 2024-11-16 17:16:07 +01:00
parent b5bdb88062
commit 466590d0ec
No known key found for this signature in database
GPG key ID: DEFC5A5B1306947D
58 changed files with 210 additions and 210 deletions

View file

@ -1404,7 +1404,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> &
for (const String &F : remaps) {
String remap = F;
String feature = remap.get_slice(".", 1);
String feature = remap.get_slicec('.', 1);
if (features.has(feature)) {
remap_features.insert(feature);
}
@ -1423,7 +1423,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> &
Vector<uint8_t> array = FileAccess::get_file_as_bytes(remapped_path);
err = save_proxy.save_file(p_udata, remapped_path, array, idx, total, enc_in_filters, enc_ex_filters, key, seed);
} else if (remap.begins_with("path.")) {
String feature = remap.get_slice(".", 1);
String feature = remap.get_slicec('.', 1);
if (remap_features.has(feature)) {
String remapped_path = config->get_value("remap", remap);
@ -2344,7 +2344,7 @@ Error EditorExportPlatform::ssh_run_on_remote(const String &p_host, const String
print_verbose(vformat("Exit code: %d, Output: %s", exit_code, out.replace("\r\n", "\n")));
}
if (r_out) {
*r_out = out.replace("\r\n", "\n").get_slice("\n", 0);
*r_out = out.replace("\r\n", "\n").get_slicec('\n', 0);
}
if (err != OK) {
return err;