From 4eb0520921493df52be495b6efc05e228ac67181 Mon Sep 17 00:00:00 2001 From: Marek Marecki Date: Wed, 19 Jun 2013 00:01:13 +0200 Subject: [PATCH] Small changes in regexp used for cleaning notifications HTML text, it now includes more characters. --- diaspy/models.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/diaspy/models.py b/diaspy/models.py index ec798cc..e78e82e 100644 --- a/diaspy/models.py +++ b/diaspy/models.py @@ -72,8 +72,9 @@ class Notification(): def __str__(self): """Returns notification note. """ - string = re.sub('', '', self.data['note_html']) + string = re.sub('', '', self.data['note_html']) string = string.strip().split('\n')[0] + while ' ' in string: string = string.replace(' ', ' ') return string def __repr__(self): -- 2.25.1