From 8661cb9bd38c29af35d785c98d0008323a1734b1 Mon Sep 17 00:00:00 2001 From: Karen Tracey Date: Sun, 21 Mar 2010 13:47:50 +0000 Subject: [PATCH] Fixed #13170: Make get_level and set_level importable from django.contrib.messages, as documented. Thanks dm, SmileyChris, tobias. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12826 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/contrib/messages/api.py | 1 + django/contrib/messages/tests/base.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/django/contrib/messages/api.py b/django/contrib/messages/api.py index 715973761e..65fd188bf0 100644 --- a/django/contrib/messages/api.py +++ b/django/contrib/messages/api.py @@ -4,6 +4,7 @@ from django.utils.functional import lazy, memoize __all__ = ( 'add_message', 'get_messages', + 'get_level', 'set_level', 'debug', 'info', 'success', 'warning', 'error', ) diff --git a/django/contrib/messages/tests/base.py b/django/contrib/messages/tests/base.py index 8be2e018ff..2dea5a46d0 100644 --- a/django/contrib/messages/tests/base.py +++ b/django/contrib/messages/tests/base.py @@ -2,8 +2,8 @@ from django import http from django.test import TestCase from django.conf import settings from django.utils.translation import ugettext_lazy -from django.contrib.messages import constants, utils -from django.contrib.messages.api import MessageFailure, get_level, set_level +from django.contrib.messages import constants, utils, get_level, set_level +from django.contrib.messages.api import MessageFailure from django.contrib.messages.storage import default_storage, base from django.contrib.messages.storage.base import Message from django.core.urlresolvers import reverse