1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 06:57:45 +00:00

copy: Use StringBuilder::join()

This commit is contained in:
Andreas Kling 2020-03-20 14:40:17 +01:00
parent 5db8940c9e
commit 3823d13e21

View file

@ -66,13 +66,7 @@ Options parse_options(int argc, char* argv[])
} else { } else {
// Copy the rest of our command-line args. // Copy the rest of our command-line args.
StringBuilder builder; StringBuilder builder;
bool first = true; builder.join(' ', text);
for (auto& word : text) {
if (!first)
builder.append(' ');
first = false;
builder.append(word);
}
options.data = builder.to_string(); options.data = builder.to_string();
} }