Added a before_action method to verify the user is signed in before taking certain actions.