fixed bug with views.py