(a) Each offense for which the person is found guilty except for insanity is a misdemeanor; and
(b) The court finds that the person is affected by a qualifying mental disorder and presents a substantial danger to others that requires commitment.
(2) The total period of commitment under this section may not exceed the maximum sentence provided by statute for the crime for which the person was found guilty except for insanity.
(3) If the superintendent of the state mental hospital or the director of the facility to which the person is committed determines that a person committed under this section is no longer affected by a qualifying mental disorder or, if so affected, no longer presents a substantial danger to others that requires commitment, the superintendent or director shall file notice of that determination with the committing court. Upon filing of the notice, the superintendent or director shall discharge the person from custody. [1981 c.711 §3; 1983 c.800 §7; 1987 c.903 §36; 1995 c.529 §1; 2011 c.708 §37; 2011 c.724 §4; 2017 c.634 §8; 2019 c.329 §4]