BAKERSFIELD, Calif. (KGET) — A pit bull that attacked an 8-year-old girl Thursday in south Bakersfield was shot and killed by a neighbor, police said.

The child was entering her home on Berryessa Court when the stray dog bit her, police said. The child’s mother and a neighbor tried to free her but the dog wouldn’t let go.

Another neighbor fired a single round, killing the dog, according to police.

The girl suffered minor to moderate injury, police said. The pit bull did not have a microchip and no owner could be found. Bakersfield City Animal Control responded to the scene.

The gun was legally-owned, police said. Berryessa Court is south of East Panama Lane and east of South H Street.