If a person is committed or is in the custody of any officer on any charge by virtue of a warrant or commitment of a justice of the peace, such person shall not be discharged from imprisonment or custody on the ground of a mere defect of form in the warrant or commitment.
A.R.S. § 13-4133