(Inglewood) Josh Allen accounted for three touchdowns, Tyler Bass made a 29-yard field goal with 28 seconds left and the Buffalo Bills defeated the Los Angeles Chargers 24-22 on Saturday to improve their probabilities of participating in the playoffs.

Allen reached the end zone twice himself and had a touchdown pass, becoming the first player in NFL history to have four straight seasons with at least 40 combined touchdowns.

Bass’ game-clinching field goal came at the end of a 13-play, 64-yard offensive drive, including a 15-yard pass from Allen to Khalil Shakir on a third down.

The Bills (9-6) have won four of their last five meetings. They are in the heart of a race with the Indianapolis Colts (8-6) and the Houston Texans (8-6) for the last two playoff tickets.

The Buffalo team received a little help from the Pittsburgh Steelers, who defeated the Cincinnati Bengals earlier Saturday.

The Bills committed three turnovers to help the Chargers stay in the game. The California club played its first match under the leadership of head coach Giff Smith, appointed interim after the dismissals of his predecessor Brandon Staley and general manager Tom Telesco on December 15.

Cameron Dicker made a career-high five field goals and Easton Stick passed for 210 yards for the Chargers (5-10), who have lost six of their last seven games.