From a07a352d1ca37bdf0f52f4547ad2a67be23f4eef Mon Sep 17 00:00:00 2001 From: udf Date: Sun, 10 Jun 2018 21:10:48 +0200 Subject: [PATCH] use None as default parameter instead of empty list --- stdplugins/markdown.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stdplugins/markdown.py b/stdplugins/markdown.py index 50d69f9..976c936 100644 --- a/stdplugins/markdown.py +++ b/stdplugins/markdown.py @@ -70,9 +70,9 @@ MATCHERS = [ ] -def parse(message, old_entities=[]): +def parse(message, old_entities=None): entities = [] - old_entities = {e.offset: e for e in old_entities} + old_entities = {e.offset: e for e in old_entities or []} i = 0 message = _add_surrogate(message)