From 5b87276841f5dd7d29e2e02fff5540dabc40bfa8 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Fri, 7 May 2021 11:58:21 +0200 Subject: [PATCH] LibDiff: Convert StringBuilder::appendf() => AK::Format --- Userland/Libraries/LibDiff/Format.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Userland/Libraries/LibDiff/Format.cpp b/Userland/Libraries/LibDiff/Format.cpp index 84e211cce4..147eab48df 100644 --- a/Userland/Libraries/LibDiff/Format.cpp +++ b/Userland/Libraries/LibDiff/Format.cpp @@ -7,16 +7,15 @@ #include "Format.h" #include #include -#include namespace Diff { String generate_only_additions(const String& text) { auto lines = text.split('\n', true); // Keep empty StringBuilder builder; - builder.appendf("@@ -0,0 +1,%zu @@\n", lines.size()); + builder.appendff("@@ -0,0 +1,{} @@\n", lines.size()); for (const auto& line : lines) { - builder.appendf("+%s\n", line.characters()); + builder.appendff("+{}\n", line); } return builder.to_string(); }