Show More
@@ -32,7 +32,7 b' class FilenameExtension(TraitType):' | |||||
32 |
|
32 | |||
33 | def validate(self, obj, value): |
|
33 | def validate(self, obj, value): | |
34 | try: |
|
34 | try: | |
35 |
value = py3compat.cast_ |
|
35 | value = py3compat.cast_unicode_py2(value) | |
36 | except UnicodeDecodeError: |
|
36 | except UnicodeDecodeError: | |
37 | msg = "Could not decode {!r} for FileExtension trait '{}'." |
|
37 | msg = "Could not decode {!r} for FileExtension trait '{}'." | |
38 | raise TraitError(msg.format(value, self.name)) |
|
38 | raise TraitError(msg.format(value, self.name)) |
General Comments 0
You need to be logged in to leave comments.
Login now