The bald eagle wounded in a shooting and found in Petaluma last week was euthanized at UC Davis Veterinarian Hospital Friday morning after an examination discovered it had serious heart damage possibly caused by lead poisoning, according to the group Sonoma County Wildlife Rescue.

The decision to euthanize the bird came after veterinary hospital staff on Thursday ran tests on the eagle in preparation for surgery to fix a broken bone in its right wing, where a lodged pellet was found after it was captured, the rescue group said. The injury left the eagle unable to fly.

Blood work done earlier in the week showed heightened lead levels in the eagle’s system but Thursday’s examination revealed the full extent of the lead poisoning, which was severe and could not be treated, Dan Famini, a veterinarian for Sonoma County Wildlife Rescue, said in a Facebook post Friday. Lead poisoning can happen when eagles eat animals shot with lead ammunition. A ban on such ammunition for use in hunting will go into effect in California on July 1.

“We had no idea that its heart was in so bad shape,” said Doris Duncan, executive director of the local rescue group. “It was very upsetting because we had so much hope for the bird.”

Further testing will look at the cause of the heart damage, the Facebook post said.

The rescue group was first told of the bald eagle on Jan. 31 when someone reported an injured bird near Corona Road in Petaluma. Rescuers took the raptor into their custody and asked community members for donations to cover the surgery and recovery costs, estimated at about $10,000.

Sonoma County Wildlife Rescue also contacted the U.S. Fish and Wildlife Service to report the shooting of the eagle, a violation of law that’s prompted an investigation, Duncan said.

The federal wildlife agents will proceed with the investigation despite the eagle’s death, she added. The federal agency did not return a call for more information on Friday.

Sonoma County Wildlife Rescue offered to return any donations made to fund the eagle’s surgery and subsequent treatment costs.

The group plans to use any retained funds to help future raptors who pass through the facility.