delivered the opinion of the court:
Respondent Tracy Servís appeals from a Sangamon County circuit court judge’s order involuntarily admitting him to a mental health facility. He argues the order must be reversed because no hearing was scheduled to be held within five days after his admission to the facility. We disagree and affirm.
I. Facts
A petition for the emergency admission of respondent was executed on January 25, 1993, and filed with the court on January 27. On January 29 the trial judge dismissed this petition, reasoning it had not been filed with the court within 24 hours after respondent was admitted to the McFarland Mental Health Center (McFarland) as required by section 3 — 611 of the Mental Health and Developmental Disabilities Code (Code) (Ill. Rev. Stat. 1991, ch. 91½, par. 3 — 611).
On the same date the trial judge filed a written order dismissing the petition. The order also stated “[respondent] shall be discharged.” A short time after dismissal of the initial petition, a second petition was filed in open court alleging respondent was subject to involuntary admission. An order for detention, examination, and diagnostic evaluation was entered the same day. The order directed respondent be evaluated by a clinical psychologist at McFarland. It did not indicate where respondent was to remain until the examination occurred. Upon the advice of his attorney, respondent did not attempt to leave McFarland after dismissal of the initial petition.
Respondent was evaluated by a clinical psychologist on January 29 at 2:15 p.m. and 9:30 p.m., and was found to be in need of immediate hospitalization. A hearing on the second petition was scheduled for February 5, 1993. Respondent’s attorney made an oral motion to dismiss this petition for several reasons, including that the second hearing was untimely pursuant to section 3 — 706 of the Code because it occurred more than five business days after respondent’s initial admission to McFarland (Ill. Rev. Stat. 1991, ch. 91½, par. 3 — 706) and because respondent never left McFarland after the dismissal of the initial petition. Consequently, counsel contended, respondent had one continuous admission at McFarland and the hearing on the second petition was not scheduled within five days of respondent’s admission.
The trial judge denied respondent’s motion to dismiss on all points raised by respondent. She reasoned the untimeliness argument failed because respondent was ordered discharged upon dismissal of the first petition. Therefore, there had been two admissions of respondent into McFarland. After a hearing, respondent was found to be a person subject to involuntary admission and was ordered hospitalized in the Department of Mental Health and Developmental Disabilities. This appeal followed.
II. Analysis
Section 3 — 706 of the Code provides, in pertinent part, when a respondent is admitted to a mental health facility a hearing must be set to be held within five working days after respondent’s admission. Ill. Rev. Stat. 1991, ch. 91½, par. 3 — 706.
Respondent’s initial admission to McFarland was an emergency admission upon certification pursuant to section 3 — 602 of the Code (Ill. Rev. Stat. 1991, ch. 91½, par. 3 — 602). The petition was filed on January 27, 1993, at 3:48 p.m. It was untimely because it was not filed within 24 hours after respondent’s emergency admission pursuant to section 3 — 611 of the Code, whether it was filed on January 26, 1993, at 1 p.m. as the State argued, or on January 25, 1993, at 1:30 a.m., as argued by respondent’s attorney.
The trial judge concluded respondent’s admission to McFarland on January 26 was reasonably clear and the petition was untimely based on this admission date and time. She further concluded because of this finding it was not necessary to determine whether the admission date was January 25. This petition was dismissed and respondent was ordered discharged before the new petition was ruled on.
Respondent contends on appeal he was not actually discharged on January 29, 1993. Therefore, whether he was admitted on the first petition on January 25 or January 26, more than five days expired before the hearing on February 5, 1993, on the second petition in violation of section 3 — 706 of the Code.
The hearing on the second petition was timely. The record indicates the initial petition was dismissed and respondent was ordered discharged on January 29 at approximately noon. During the 15 minutes which passed between respondent’s discharge and the entry of an order detaining him for examination, respondent’s attorney advised respondent not to leave the premises. Although perhaps impractical, respondent could have left the premises during the 15-minute period between his discharge and the hearing on the new petition. Respondent’s counsel’s advice was realistic. However, the fact respondent remained voluntarily does not compel this court to conclude he was not discharged.
Respondent further contends his argument is not based merely on the failure to discharge him, but upon the effect of the failure to discharge him because of the untimeliness of the subsequent proceedings. We find the hearing on the second involuntary admission petition was held in a timely manner on February 5, 1993. January 29 was a Friday. January 30 and 31, 1993, were a Saturday and Sunday, respectively. The relevant section of the Code requires the hearing within five days “excluding Saturdays, Sundays and holidays.” Ill. Rev. Stat. 1991, ch. 91½, par. 3 — 706.
Affirmed.
McCULLOUGH and COOK, JJ., concur.