changeset 504:4dbc16ff2670

.lstrip() seems to be a little bit faster than .rstrip() when testing whether quoting is needed
author Franz Glasner <fzglas.hg@dom66.de>
date Sat, 18 Dec 2021 02:35:42 +0100
parents a56f1d97a3f3
children 9e5fec21e2fb
files configmix/config.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/configmix/config.py	Sat Dec 18 01:49:48 2021 +0100
+++ b/configmix/config.py	Sat Dec 18 02:35:42 2021 +0100
@@ -263,7 +263,7 @@
 
     """
     # Quick check whether all of the chars are in _QUOTE_SAFE
-    if not s.rstrip(_QUOTE_SAFE):
+    if not s.lstrip(_QUOTE_SAFE):
         return s
 
     # Slow path