Commit afccb17a by Adam Palay Committed by Usman Khalid

support unicode course names for bulk email (LMS-2118)

parent b60487c8
......@@ -374,7 +374,7 @@ def _get_source_address(course_id, course_title):
invalid_chars = re.compile(r"[^\w.-]")
course_num = invalid_chars.sub('_', course_num)
from_addr = '"{0}" Course Staff <{1}-{2}>'.format(course_title_no_quotes, course_num, settings.BULK_EMAIL_DEFAULT_FROM_EMAIL)
from_addr = u'"{0}" Course Staff <{1}-{2}>'.format(course_title_no_quotes, course_num, settings.BULK_EMAIL_DEFAULT_FROM_EMAIL)
return from_addr
......@@ -677,5 +677,5 @@ def _statsd_tag(course_title):
"""
Calculate the tag we will use for DataDog.
"""
tag = "course_email:{0}".format(course_title)
tag = u"course_email:{0}".format(course_title)
return tag[:200]
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment