(MODESTO, Calif.) -- Trent Kersey says he has known since he was a little kid that he wanted to be a police officer.
On Halloween, his longtime dream came true, about an hour after he and his wife Victoria Kersey welcomed their second child, a baby boy named Theo, at Memorial Medical Center in Modesto, California.
Theo's arrival, about a week earlier than his expected due date of Nov. 6, threw a wrench into Trent Kersey's original plan -- to graduate from San Joaquin Delta College Post Academy this week and get sworn in as a Modesto police officer.
"The day before, we were practicing rehearsals at the academy for our graduation, and then [I] came home that afternoon and talked to the wife. And then, next thing you know, we gotta go down to the hospital that night, and I had to call the academy staff and my department and let them know I wasn't gonna make it to graduation," Trent Kersey, 25, told "Good Morning America."
The father of two said it felt "bittersweet" to not be able to share the milestone with his fellow classmates, but at the same time, he was "excited" to meet his son and be there for his family. He said the staffers at his academy and the police department were all "very, very understanding" as well, but what happened next was another big surprise.
"My sergeant was just checking in on me, [making] sure things [were] OK. And then he reached out to me and said, 'Hey, how would you feel about me, the chief and other higher-ups in the department coming by and swearing you in at the hospital?'" he recalled.
Trent Kersey, who also serves in the National Guard, said he was quick to reply.
"I said, 'That'd be awesome. I'd be honored,'" the Army veteran told "GMA."
He said he then spoke with his wife and hospital staff, and with everyone on board, the Modesto Police Department brought the ceremonial swearing-in event to Victoria Kersey's hospital room.
"Theo was born, and about an hour later, the chief of Modesto PD and my sergeant [and] other higher-ups came by and swore me in," Trent Kersey said.
Frank Inacio, a recruitment sergeant, was one of the Modesto Police Department staffers who witnessed Trent Kersey getting sworn in, an event he described as a rite of passage for a police officer.
"He texted me the day before saying, 'Hey, my wife's in labor.' So we knew he wasn't going to be at graduation," Inacio recalled to "GMA." "I also knew that he was the class leader at the time, so … that's a big, big position to hold. So we knew he was going to miss an opportunity at the academy that most people don't miss. Those are big days in people's careers."
With the hospital's approval, Modesto Chief of Police Brandon Gillespie read the oath of office to Trent Kersey and Inacio presented Victoria Kersey with her husband's new police officer badge.
Inacio said the unusual swearing-in ceremony was an example of how the Modesto Police Department tries to emphasize a "family-first" approach for their community.
"This career overwhelms you. It can suck you in, and the biggest thing is letting these new officers know, 'We support you. It's family first.' They're the ones that are going to be there when this career is over. It's important to start that from the beginning," Inacio said.
The Kersey family are now back home from the hospital. Trent Kersey said he is "super excited" to one day recount what happened to his two children, 1-year-old son Maverick and baby Theo.
He added that he hopes his personal story will shine a positive light on people working in law enforcement.
"Law enforcement are people too. We're not just out there doing a job. We're also people and it proves that we care, we actually care about families and what's going on in the community," he said.