Reputation: 429
I have simple session authentication in Sinatra. However, I want to run this method on every request so that way if the user is not logged in (eg. the session variables for username, etc. are not set), then they would be redirected to the sign in page. How can I achieve this?
Upvotes: 1
Views: 326