A heroic police dog that was shot in the line of duty is heading home, one day after taking a bullet for his partner in South Florida.

K-9 Officer Casper "has done wonderful[ly]" and "is walking fairly well, all things considered," veterinarian Michele Tucker said in a video released by the Palm Beach County Sheriff's Office (PBSO).

Casper was shot on Friday in Jupiter, Florida, after PBSO deputies encountered 46-year-old Philip O'Shea, who was wanted in North Carolina in connection with a robbery. O'Shea had an extensive criminal history and tried to flee from the officers, CBS affiliate WPEC-TV reported.

Get Breaking News Delivered to Your Inbox

Sheriff Ric Bradshaw said the deputies pursued O'Shea, who crashed his vehicle. O'Shea exchanged gunfire with the officers and was killed in the ensuing gunfight.

Casper was struck in the firefight, taking a bullet meant for his partner, Bradshaw said. He was taken into surgery Friday, earning praise for his heroism from users across social media.

The PBSO said Saturday that Casper was well enough to go home. The office released a video showing Casper emerging from his pen with a protective cone around his neck, his gunshot wound clearly visible on his hind leg.

K9 Casper Returns Home K9 Casper returns home after taking a bullet that was meant for his K9 handler. Posted by PBSO - Palm Beach County Sheriff's Office on Saturday, May 13, 2017

"Casper came into us last night after suffering a gunshot wound in the left hip. He was stable when he arrived. Once we determined that the bullet had not harmed any internal organs, we proceeded to remove the bullet surgically," said Tucker, a vet with the Palm Beach Veterinary Specialists.

A x-ray showing the bullet that struck Casper PBSO Handout

The PBSO says Casper is trained to detect bombs and works as a SWAT and patrol dog. The office also notes his service record includes stints protecting the president.

"He has recovered well from anesthesia. He's on antibiotics," Tucker continued. "We're just happy that this is not a significant trauma and thankful that he's done well and appreciative for all that he's done for the county."