The first part of the bond shall be returned or the first part of the sureties lifted if the accused, defendant or person under investigation has appeared for all the acts of the proceedings, has complied with the obligations of judicial supervision and has submitted to the enforcement of the judgment.
If this is not the case, unless there is a legitimate excuse or a decision to dismiss the case, discharge, acquit or exempt the defendant from punishment, the first part of the security shall be forfeited to the State, or the debt guaranteed by the first part of the security shall be recovered.