Fix isAdmin context and public subroute handling