Commit 78b1b9c6 authored by Zenon Mousmoulas's avatar Zenon Mousmoulas

Ignore a possible locale.Error exception (from b1fe63b)

parent aff0d789
......@@ -1681,7 +1681,10 @@ def participants(request):
dets.append(i.institutiondetails)
if i.get_active_cat_enrl():
cat_exists = True
locale.setlocale(locale.LC_COLLATE, [request.LANGUAGE_CODE, 'UTF-8'])
try:
locale.setlocale(locale.LC_COLLATE, [request.LANGUAGE_CODE, 'UTF-8'])
except locale.Error:
pass
dets.sort(cmp=locale.strcoll,
key=lambda x: unicode(x.institution.
get_name(lang=request.LANGUAGE_CODE)))
......
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