PHILADELPHIA (AP) — Brad Miller hit a two-run single in the 10th inning to give the Texas Rangers a 2-1 win over the Philadelphia Phillies on Wednesday night.

Marcus Semien doubled and had two hits for the Rangers, who have won a season-high four in a row after sweeping the two-game series with the Phillies.

READ MORE: WATCH: Penn Student Calls For Sixers To Fire Doc Rivers During Graduation Ceremony

Nick Castellanos doubled and had three hits for Philadelphia. The Phillies have lost four of five since a four-game winning streak.

Philadelphia’s Zack Wheeler and the Rangers’ Martin Perez each were stellar in starting roles.

Wheeler went 7 2/3 innings, giving up six hits and getting seven strikeouts, lowering his ERA to 4.10. Phillies manager Joe Girardi was loudly booed when he lifted last year’s NL Cy Young runner-up with two outs in the eighth and just 78 pitches.

Perez went seven innings with four hits, four walks and four strikeouts. The 31-year-old left-hander’s ERA is at 2.25.

Matt Bush (1-1) got the final out of the ninth.

Texas’ Adolis Garcia started the extra frame on second base and went to third on Kole Calhoun’s flyout to deep right. After Mitch Garver walked, pinch-runner Eli White stole second. Pinch-hitter Nick Solak struck out before Miller lined a 1-0 slider from Brad Hand (1-1) to right to score Garcia and White.

Joe Barlow gave up a run in the bottom of the 10th on Odubel Herrera’s pinch-hit RBI groundout, but got his third save in as many chances.

READ MORE: Lt. Gov. John Fetterman Votes From Hospital With Emergency Absentee Ballot After Suffering Stroke

Castellanos was back in the lineup after missing Tuesday’s game due to the birth of his son.

It looked like the Phillies had gotten on the board in the sixth when Castellanos lined Perez’s first pitch to right. First-base umpire Erich Bacchus signaled that it was a home run, but the call was overturned after a video review showed a fan reached over the railing and touched the ball while it still was in play.

Castellanos went to second base instead after the double, but the inning ended when Bryce Harper followed with a flyout to left field.

TRAINER’S ROOM

Rangers: Perez was drilled on the back of the leg on J.T. Realmuto’s liner in the second inning. The lefty made a play to get Realmuto out and limped back to the mound, but stayed in the contest following a visit from the trainer.

Phillies: Harper will continue to serve as the team’s designated hitter for the foreseeable future. He hasn’t played right field since April 16 due to a strained right elbow and last tested it out by throwing on April 26 and 27. He does not have a date when he is scheduled to throw again. … SS Gregorius and LF Kyle Schwarber collided on Garver’s single to short left in the seventh. It appeared that Gregorius’ leg hit Schwarber in the face. Both stayed in the game.

UP NEXT

Rangers: After an off day, Texas begins a three-game series at New York Yankees on Friday night. Texas RHP Glenn Otto (1-0, 2.89) is scheduled to face Yankees RHP Gerrit Cole (2-0, 3.00).

MORE NEWS: Poll Workers At Kimmel Center Say Pa. Primary Election Turnout Down Considerably From 2020 Presidential Campaign

Phillies: Host the first-place New York Mets for a four-game series beginning on Thursday night when Philadelphia RHP Aaron Nola (1-3, 3.90) opposes Mets RHP Taijuan Walker (0-0, 0.00).