The trial court properly awarded Attorney General Becerra attorney fees under CCP 1021.5 for successfully defending this lawsuit which produced an earlier published opinion holding that Gov. Code 12503’s requirement that the candidate for Attorney General must have been admitted to practice for five years before the election was satisfied by inactive as well as active membership in the State Bar.  That appellate victory vindicated an important public right.  The financial burden of the litigation justified the award.  Becerra’s salary as Attorney General was not a direct benefit of his victory in the lawsuit, but rather a benefit of his having won the election. The trial judge also properly awarded Becerra about half the fees he incurred in bringing his fee motion since plaintiff’s opposition to the motion raised novel questions which required a substantial investment of time to oppose.