Sanaa, Yemen (CNN) -- At least 31 people were killed and more than 23 injured when government airstrikes hit a mosque and other buildings in downtown Jaar on Monday, a security official said.
A senior security official in Jaar confirmed the air attacks but called it a mistake. He confirmed that wanted militants were at the area of the attack one hour earlier.
"The air raids were targeting extremists in the area. We give our condolence to the families who lost a loved one," said the official, who is not authorized to talk to media.
The air raid hit a governmental compound, which comprises a mosque, residential area, a hospital, and governmental offices.
Eyewitnesses said that at least three aircraft were seen flying over the skies of Jaar just minutes before the attack took place.
An air strike hit a side of a mosque causing damages to neighboring shops as well. Also hit was school, a court building and a government complex.
Locals in Jaar were angered at why government forces were attacking areas where civilians reside and not targeting places were militant's control. "All those who died were civilians who we know and were never involved in any violence," said Nasser Attaf, a resident of Jaar.
He added, "Actions like this will force locals to attack government forces to avenge for their loved ones killed by the government."
Jaar is the largest town in Abyan province, and it is considered a stronghold for extremist fighters.
"The government continues to seek militant hideouts and because militants tend to hide within civilian lines, such tragic mistakes happen," the security official said.