Changes between Version 1 and Version 2 of Ticket #24068
- Timestamp:
- Jan 1, 2015, 7:55:56 AM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #24068 – Description
v1 v2 16 16 {{{#!diff 17 17 diff --git a/django/core/management/base.py b/django/core/management/base.py 18 index 869a11b.. dc22d7410064418 index 869a11b..318740f 100644 19 19 --- a/django/core/management/base.py 20 20 +++ b/django/core/management/base.py 21 @@ -107,11 +107,1 3@@ class OutputWrapper(object):21 @@ -107,11 +107,12 @@ class OutputWrapper(object): 22 22 return getattr(self._out, name) 23 23 … … 29 29 - self._out.write(force_str(style_func(msg))) 30 30 + ending = self.ending if ending is None else ending 31 + if ending: 32 + if msg.endswith(ending): 33 + msg = msg[:-len(ending)] 31 + if ending and msg.endswith(ending): 32 + msg = msg[:-len(ending)] 34 33 + msg = force_str(style_func(msg)) + ending 35 34 + self._out.write(msg) 36 37 38 class BaseCommand(object):39 35 }}}