Updated

NASA is replacing some space shuttle connections in hopes of plugging a gas leak and launching Discovery to the international space station on Sunday, after delays of more than a month.

Discovery was supposed to blast off Wednesday night with a crew of seven and one final set of solar wings for the space station. But hydrogen gas began leaking as the shuttle was being fueled, and NASA called everything off.

The leak occurred near the line that vents hydrogen gas out of the external fuel tank. On Thursday, workers were removing the quick-disconnect unit at that location and a pair of seals, and planned to replace the parts Friday.

NASA spokesman Allard Beutel said shuttle managers have "high confidence" that all the repair work can be done in time to launch Discovery at 7:43 p.m. Sunday. That would lead to a slightly shortened mission and one less spacewalk than planned, in order to make way at the space station for a Russian Soyuz spacecraft scheduled for liftoff on March 26.

The Soyuz is a higher-priority mission. It will deliver a fresh crew to the space station.

Discovery was supposed to spend 14 days in orbit. If the launch occurs Sunday, then the mission will be reduced to 13 days and there will be three spacewalks instead of the planned four, Beutel said.

Because of the impending Soyuz mission, Discovery must be flying by Tuesday. Otherwise, the shuttle will have to wait until April.

Liftoff originally was targeted for mid-February, but NASA kept delaying the flight because of concern over hydrogen gas valves in Discovery's engine compartment. Extra tests were ordered to ensure that the three valves in Discovery were safe to fly and would not break like one did during the last shuttle launch in November.