File tree 2 files changed +4
-4
lines changed
2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change 4
4
5
5
from django .contrib .contenttypes .models import ContentType
6
6
from django .db import models
7
- from django .utils .encoding import python_2_unicode_compatible
7
+ from django .utils .encoding import python_2_unicode_compatible , force_text
8
8
from django .utils .translation import ugettext_lazy as _
9
9
10
10
from .node import NodeAccessor
@@ -21,7 +21,7 @@ class Meta:
21
21
verbose_name_plural = _ ('Reference descriptors' )
22
22
23
23
def __str__ (self ):
24
- return str (self .content_type )
24
+ return force_text (self .content_type )
25
25
26
26
def get_search_fields (self ):
27
27
if not self .search_fields :
Original file line number Diff line number Diff line change 1
1
# -*- coding: utf-8 -*-
2
2
3
3
from django .db import models
4
- from django .utils .encoding import python_2_unicode_compatible , smart_text
4
+ from django .utils .encoding import python_2_unicode_compatible , force_text
5
5
from django .utils .translation import ugettext_lazy as _
6
6
7
7
@@ -37,7 +37,7 @@ def __bool__(self):
37
37
return False
38
38
39
39
def __str__ (self ):
40
- return str (_ ('Undefined' ))
40
+ return force_text (_ ('Undefined' ))
41
41
42
42
def __str__ (self ):
43
43
return self .definition .name
You can’t perform that action at this time.
0 commit comments