From 5c2e83eef59c9591d1b5c65e5f265fc80271f283 Mon Sep 17 00:00:00 2001 From: Malcolm Tredinnick Date: Sun, 11 Mar 2007 10:37:33 +0000 Subject: [PATCH] Fixed some i18n markup on date error messages. Thanks, Bastian Kleineidam. Refs #3069. git-svn-id: http://code.djangoproject.com/svn/django/trunk@4702 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/core/validators.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/django/core/validators.py b/django/core/validators.py index ebfbd3961e..6985228a00 100644 --- a/django/core/validators.py +++ b/django/core/validators.py @@ -140,7 +140,8 @@ def _isValidDate(date_string): try: date(year, month, day) except ValueError, e: - raise ValidationError, gettext('Invalid date: %s.' % e) + msg = gettext('Invalid date: %s') % gettext(str(e)) + raise ValidationError, msg def isValidANSIDate(field_data, all_data): if not ansi_date_re.search(field_data):