diff configmix/config.py @ 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 dffa692751b1
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