Update views.py

The error I had last night was because I had not returned the redirect statement for the login check. I was hoping hat the redirect would mean the user would be directed back to the create/edit/details page once they were signed in, but it doesn't work that way. This version should be correct. I'll see about the details/edit pages this afternoon.