Skip to content

Commit

Permalink
Fixed #12754 -- Reintroduced style.ERROR_OUTPUT as an alias for style…
Browse files Browse the repository at this point in the history
….ERROR. Django doesn't need this itself, but it would be a backwards incompatible change to remove it. Thanks to Jeff Balogh for the report.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12376 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
freakboy3742 committed Feb 3, 2010
1 parent f9a33cb commit de35bb4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions django/core/management/color.py
Expand Up @@ -35,6 +35,9 @@ class dummy: pass
for role in termcolors.PALETTES[termcolors.NOCOLOR_PALETTE]: for role in termcolors.PALETTES[termcolors.NOCOLOR_PALETTE]:
format = color_settings.get(role,{}) format = color_settings.get(role,{})
setattr(style, role, termcolors.make_style(**format)) setattr(style, role, termcolors.make_style(**format))
# For backwards compatibility,
# set style for ERROR_OUTPUT == ERROR
setattr(style, 'ERROR_OUTPUT', style.ERROR)
else: else:
style = no_style() style = no_style()
return style return style
Expand Down

0 comments on commit de35bb4

Please sign in to comment.