From 4c600255d74b7e058ffa4d0c729c7e495e61b484 Mon Sep 17 00:00:00 2001 From: Vincent Le Gallic Date: Thu, 14 Nov 2013 01:33:41 +0100 Subject: [PATCH] [self_improvement] Using .lower() on avant and apres when case_insensitive --- basile.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/basile.py b/basile.py index 63f8d1c..2fedf6e 100755 --- a/basile.py +++ b/basile.py @@ -76,6 +76,8 @@ def is_something(chain, regexp=None, matches=[], avant=u".*(?:^| )", apres=u"(?: Si ``regexp`` est fournie, c'est simplement elle qui est testée""" if not case_sensitive: chain = chain.lower() + apres = apres.lower() + avant = avant.lower() if regexp == None: regexp = regex_join(matches, avant, apres) regexp = re.compile(regexp) -- 2.39.2