Update views.py

fix for python 3.3(or for all python3 versions)