From 5003f474b26505c9bfc6c44d1f78af76ff8f2634 Mon Sep 17 00:00:00 2001 From: Leonard Richardson Date: Fri, 24 Mar 2023 09:44:12 -0400 Subject: Using a format string is very slightly slower than just adding all the bits of the string together. --- bs4/formatter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bs4/formatter.py') diff --git a/bs4/formatter.py b/bs4/formatter.py index 83cc1c5..c821318 100644 --- a/bs4/formatter.py +++ b/bs4/formatter.py @@ -97,7 +97,7 @@ class Formatter(EntitySubstitution): else: indent = ' ' self.indent = indent - + def substitute(self, ns): """Process a string that needs to undergo entity substitution. This may be a string encountered in an attribute value or as -- cgit v1.2.3