Replace obvious unicode() with text_type.
Merge branch 'master' into issue38_11