Whenever a person is charged with committing an assault or aggravated assault or a battery or aggravated battery upon a code inspector, as defined in s. 162.04(2), while the code inspector is engaged in the lawful performance of his or her duties and when the person committing the offense knows or has reason to know the identity or employment of the victim, the offense for which the person is charged shall be reclassified as follows:(1) In the case of aggravated battery, from a felony of the second degree to a felony of the first degree.
(2) In the case of aggravated assault, from a felony of the third degree to a felony of the second degree.
(3) In the case of battery, from a misdemeanor of the first degree to a felony of the third degree.
(4) In the case of assault, from a misdemeanor of the second degree to a misdemeanor of the first degree.