Updated

Cole Hamels shrugged off a stiff shoulder that got his manager worried a bit.

Livan Hernandez pitched 6 2-3 strong innings and drove in two runs with a pair of singles, helping the Washington Nationals beat the Philadelphia Phillies 4-2 Friday night.

The Phillies have a healthy lead in the division and lead the majors with a 77-41 record. They're just hoping to avoid any serious injuries heading into the postseason.

So when Charlie Manuel suggested Hamels (13-7) might have some arm trouble, it raised some eyebrows.

"His shoulder was stiff," Manuel said. "There's definitely concern there, I guess. I'm sure they'll check it out."

But the All-Star lefty said it's no big deal.

"I just wasn't able to get loosened up," Hamels said. "It's that part of year where you fatigue a little bit and you have to battle through it."

Hernandez (7-11) rebounded from a rough outing at Colorado last Saturday. He gave up one unearned run and four hits to stifle the streaking Phillies, who were coming off a franchise-best 9-1 road trip.

Hamels lasted just five innings, his third-shortest outing this season. He allowed three runs, six hits and tied his season-high with four walks. Hamels gave up two runs or less in 14 of his previous 15 starts.

"I want to have success so it's tough when you can't locate pitches," he said. "It's just one of those times of the year where you're traveling and pitching a lot of innings and you just have to battle through it."

Hernandez baffled the Phillies with his assortment of offspeed pitches. He twice fanned Hunter Pence on curveballs in the 60s. In three at-bats against the veteran righty, Pence swung and missed at five pitches between 66-69 mph.

Tyler Clippard retired the four batters he faced, and Drew Storen finished for his 31st save in 35 tries. Storen allowed a run on a sacrifice fly by Pence.

Hamels worked out of a jam in the first, but couldn't do it again in the second. Wilson Ramos led off with a single and Laynce Nix walked. After Ian Desmond struck out, Hernandez singled off shortstop Jimmy Rollins' glove to score Ramos. Rick Ankiel followed with an RBI single to make it 2-0.

The Phillies cut it to 2-1 in the bottom half on an RBI single by Wilson Valdez. Ryan Howard reached on second baseman Danny Espinosa's fielding error to start the inning and scored on Valdez's liner to center.

An RBI groundout by Jayson Werth in the fifth put the Nationals up 3-1. Washington had the bases loaded with no outs and a 3-0 count on Jonny Gomes, but only scored one. Gomes flied out to shallow right before Werth hit a slow roller to first base to drive in Ankiel.

Hernandez singled in another run in the sixth off Kyle Kendrick. He fouled off a sacrifice bunt before grounding a single up the middle to score Desmond.

Hernandez, who has 10 career homers, is batting .231 with seven RBIs this season.

This was Werth's second trip to Philadelphia since signing a $126 million, seven-year contract with Washington. Werth heard a mixture of boos and cheers. A fan in right field held up a sign that read: "Not Werth a Pence."

Notes: Former Phillies All-Star 1B John Kruk was inducted into the team's Wall of Fame. Kruk, a baseball analyst on ESPN, took a shot at people who criticize Philadelphia fans. "I hear a lot of people say: 'It's tough to play in front of the fans in Philadelphia,'" Kruk said. "To those people, I say: 'You didn't have the guts to succeed here.'" ... A crowd of 45,762 was the 196th straight sellout at Citizens Bank Park, including postseason play.