MOGADISHU (Reuters) - The U.S. military said on Thursday it had killed two militants in an air strike in Somalia this week during a battle between U.S. and Somali government troops and al Shabaab Islamist fighters.

The military’s Africa Command (Africom) said the strike was carried out on Sept. 11, in the central Somali village of Mubaraak, west of the capital Mogadishu.

“The U.S. airstrike was conducted against an enemy fighting position in self-defense after U.S. and partner forces came under attack,” Africom said in a statement.

Two militants were killed and a third one wounded during the strike which did not cause any civilian casualties or injuries, Africom said. It said one friendly soldier from the “partner force” was killed in the combat, and no Americans were killed.

Al Shabaab had said on Wednesday that it had killed some soldiers during that fighting.

The United States has ramped up operations in Somalia since last year after President Donald Trump loosened the rules of engagement.

U.S. forces are supporting a U.N.-backed Somali government against the rebels, who have lost control of most of Somalia’s towns and cities since withdrawing from the capital Mogadishu in 2011 but retain a strong presence in areas outside the capital.