Who was the republican advised by Juan hernandez