What was the function of the judicial branch?