Fixed expected character buffer object issue with Django 1.6