fix error in views.py