oss2019 / crispy-ai

An intelligent bot that listens and summarises lectures to deliver content that is crisp and to-the-point
MIT License
7 stars 14 forks source link

Make Users Home accessible only when logged in #25

Closed NeuralFlux closed 5 years ago

NeuralFlux commented 5 years ago

Currently, localhost:8000/users/ is User Home. But the problem is that any person, even if not logged in, can go there. So make sure that route is accessible only to logged in users.

Redirect them to login if not logged in.

vedangj044 commented 5 years ago

We have already coded this. In previous commits, we included in views.py the redirection logic. Are to referring to something else.

svp19 commented 5 years ago

No,for security purposes I believe he is talking about adding a specific decorator - do see if you can find it ;)

NeuralFlux commented 5 years ago

We have already coded this. In previous commits, we included in views.py the redirection logic. Are to referring to something else.

Though we've done it before using simple logic, there's a more "pythonic" and developer way of doing it. This issue is all about finding it :stuck_out_tongue_winking_eye:

vedangj044 commented 5 years ago

Ok, got it, I initially used the @login_required decorator, but has some issues. It was got lazy to switch to this approach. I would fix this issue. Kindly assign it to me