Joe Pavelski scored three goals, Antti Niemi stopped 32 shots and the San Jose Sharks ended a three-game losing streak with a 4-2 win over the Arizona Coyotes on Friday night.

San Jose tightened up after falling into a 2-0 hole in the first period. Pavelski scored twice in the second to reach the 30-goal mark for the third time in his career. He added an empty-net goal for his fourth career hat trick.

Barclay Goodrow also scored to help Sharks coach Todd McLellan reach 300 wins in 515 career games. Anaheim's Bruce Boudreau is the only coach in NHL history to reach the milestone faster, 496 games.

Mark Arcobello had a goal in his Arizona debut to become the second player in NHL history with a point with four teams in the same season, joining Dennis O'Brien in 1977-78. Martin Erat also scored for the Coyotes.