Nicaraguan legislators reversed course Friday and backed President Violeta Chamorro's veto of a 25 percent military spending cut they approved last week.

Chamorro said Tuesday she was vetoing the decision to slash about $20 million from a proposed $78.6 million in military spending because it would interfere with efforts to reduce the size of the armed forces.Legislators of various parties belonging to the National Opposition Union, or UNO, met with Chamorro for several hours before Friday's vote in the National Assembly, saying they would support her veto if she agreed to oust Humberto Ortega as chief of the country's armed forces.

Chamorro did not agree to their demands, but she picked up considerably more than the 46 votes she needed for the veto. The National Assembly, made up of 39 Sandinista legislators, voted 79-21 to support the veto.

Total proposed government spending for 1991 is $500 million.

Sandinistas, who ruled the country from 1979-89, have pressured Chamorro to back the proposed $78.6 million in military spending.

The military cut approved last week triggered grenade attacks on the homes and unoccupied cars of legislators who voiced strong support for the military spending cuts.

UNO legislators who voted against the veto said they would have supported it if Chamorro had agreed to replace Humberto Ortega, brother of former Sandinista President Daniel Ortega, as head of the country's armed forces.