NEW YORK – Protecting leads really hasn’t been a problem for the Flyers this season. But it was on Saturday.

Leading by two goals after two periods, the Flyers let the lead slip in the third, then wound up losing to the New York Rangers in a shootout, 5-4, at Madison Square Garden.

New York won the shootout, 2-0. It was the Flyers’ third straight shootout loss after winning its first five this season.

The Flyers had two power-play opportunities in overtime but could not convert. It is the Flyers’ first loss of the season when leading after two periods (10-1).

“This group is going to have to learn,” coach Rick Tocchet said. “We led 4-2, had a couple opportunities to score and then you leave it to chance. You can’t take your foot off and we did.”

Not scoring on either OT power play was a killer.

“Got to score there,” Tocchet said. “Too slow with the four-on-three I thought with moving the puck. We just have to learn how to handle pressure. Take the point when we thought we should have had two.

The Flyers started the third strong, but New York’s Vincent Trocheck scored at 9:13. Then thanks to a delay of game penalty on Rasmus Ristolainen, Mika Zibanejad connected with 2:34 to play to even the score.

One bright spot for the Flyers: Denver Barkey, called up from the Lehigh Valley Phantoms to make his NHL debut, assisted on each of the Flyers’ first two goals.

They Flyers looked like they were on their way to victory after a brilliant second period. It’s rare enough to score an even-strength, a power-play and a shorthanded goal in the same game. But all in one period?

The Flyers pulled that rare hat trick in just 7:31 of the second, then added fourth goal in the frame.

The Rangers held a 1-0 lead at the first intermission. Travis Sanheim scored from the slot on a power play at 6:42 to kick off the middle-frame scoring parade. Just 23 seconds later, Owen Tippett notched his 10th goal of the season with a wrist shot past New York goalie Igor Shesterkin. At 10:18, Trevor Zegras scores just three seconds into a power play.

Then Rodrigo Abols made it 4-2 with a shorthanded goal at 14:36. It’s the Flyers’ first shorthanded goal of the season.

In the end, it was a disappointing outcome for the Flyers, who finished a four-game trip 1-1-2.

“You want to get as many points as you can,” Tippett said. “And not give any up. It’s one point, we would like to have two. Just need to work on it.”

Added Zegras: “I thought we were playing better in the third than we normally have. The power play, I think it’s something we have to get a lot better at. Two four-on-threes in the overtime, you’ve got to come up with a goal there.”

• • •

Saturday was just about all Barkey could ask for in his first game.

“I was happy with the game, obviously, but not the outcome,” he said. “I was just looking to get out there and get comfortable. I was happy with the way I played but I wanted a win.”

Barkey was trying to take a nap before a Phantoms game when he got the call from GM Danny Briere on Friday.

“I was tossing and turning in bed, getting ready for a game in Lehigh,” he said. “I couldn’t fall asleep. I rolled over to check the time on my phone, saw a few missed calls from Danny, he said to call back ASAP. It was a cool moment.”

Barkey came off two Memorial Cup championships with the OHL London Knights before he went pro this year. He’s made a nice transition to Lehigh Valley.

Tocchet was impressed.

“Probably one of the ones who won a lot of battles,” Tocchet said. “Good player. I like him a lot.”

Can Barkey stick with the big team?

“Well the play he played (today),” Tocchet said. “The way he competes, yeah. I’m going to fight for him. I know it’s a short sample size but he’s a good little player.”

• • •

NOTES >> The Flyers return to action on Monday to host Vancouver in the final home game before the Christmas break. … The Flyers’ Carl Grundstrom played in his 300th NHL game. … Daniel Briere said Alex Bump, playing for Lehigh Valley, was recently injured and is expected to miss seven to 10 days.