It is the duty of the State's Attorney of the county wherein any person is imprisoned in pursuance of a conviction under any provision of this Act to resist before the courts any application for habeas corpus that may be prosecuted by such person so convicted.
20 ILCS 1805/99