Enforcing Authentication for Certain Views

(Immanuel) #1

Hello everyone, I’m building an application that uses Social Authentication with GitHub only. How do I enforce login to access certain views? Will @login_required do just fine?

(Pascal Njue) #2

@login_required will work just fine. If an unauthenticated user trys to access the URL, it will redirect them to the login URL.