Ensure user is logged in before allowing access to routes