In a consolidated appeal of and habeas corpus petition involving the single issue of whether the two year enhancement set forth in Penal Code section 12022.1 be imposed on defendant/appellant/petitioner for conviction of a felony in a 'secondary offense' while on bail on a felony in a 'primary offense,' when the primary offense is settled by a no contest plea to a misdemeanor: 1) the judgment is affirmed where there is no error on the record; and 2) the petition is granted where the two-year enhancement under section 12022.1 does not apply when the primary offense is reduced to a misdemeanor and resolved by a plea of no contest.