PLEASANTVILLE, N.Y. (CBSNewYork) — Investigators on Thursday said a corroded pipe was to blame for a gas leak that forced evacuations on the Pleasantville campus at Pace University, and left some students stuck sleeping in the gym.

Gas was turned off on Wednesday at the Pleasantville campus, leaving several buildings – including all the dorms – with no heat or hot water.

READ MORE: Police Arrest Boyfriend Of Woman Found Stabbed To Death On Long Island

All classes continued as scheduled, but for the safety of the Pace Westchester community in Pleasantville and Briarcliff, all dorms on the Pleasantville campus were evacuated and locked up at 10 p.m. Wednesday, according to the announcement.

Those students who had the option of going home to their family’s houses were advised to do so, and were ordered to notify school officials if they were. Pleasantville students were also allowed to stay with students in the Briarcliff campus dorms, which remained open.

READ MORE: Man Arrested In Connection To Fatal Shooting In Jersey City

The Wilcox Hall gym was also used as a temporary housing site for students who could not go home or stay in a Briarcliff dorm. Cots were set up in the gym for students to sleep, and students were advised to take what they needed for a few days because dorms would remain off limits.

The complete list of buildings closed because of the gas shutdown included the Kessel Student Center, the Goldstein Fitness Center, Martin Hall, North Hall, Townhouses, Paton House, the Environmental Center Classroom, the Administration Building, and the Gannett Houses.

By Thursday morning, Con Edison said heat and hot water had been restored to two buildings.

MORE NEWS: NYPD Lieutenant Shot In Ankle Apprehending Suspect In The Bronx

School officials said Thursday that portable boilers were being brought in as a temporary solution.