One week ago, Michigan State sat on top of the world, fresh off a 37-33 win over Michigan and a No. 3 ranking in the College Football Playoff standings.

The Spartans were on track for something historical — all they had to do was win at Purdue.

Well, the Boilers — the Spoilers — had other plans, stunning MSU 40-29 in West Lafayette and notching their second win over a top-5 team this season.

Michigan State’s pass defense was suspect, and that’s putting it lightly, vs. the Boilers, whose QB Aidan O’Connell threw for a career-high 536 yards while picking apart the Big Ten’s worst secondary. It was a clinic. O’Connell completed every type of throw there is to complete.

Long balls?

Yeah, he had a couple of them to WR David Bell, who was on the receiving end of pass plays going 53, 50 and 42 yards en route to a 217-yard day at the Spartans’ expense.

The season is nearing an end, and the Spartans still remain in the hunt for a Big Ten championship. But they won’t produce a 10- or 11-win campaign if they remain lax in the secondary. There isn’t a team in recent memory that has given up 300-plus yards per game and kept afloat in the race for a title. Just doesn’t happen.

Michigan State has been lucky. Even before Saturday, the Spartans had been tested by just about every QB they’ve faced. Despite lots of stats, no QB has been able to knock out MSU. O’Connell did that Saturday, punch-by-punch.

With Maryland up next, Michigan State has to be careful and not let things spiral out of control. Another loss would effectively remove them from Big Ten-title contention. The Terps just got upended by Penn State, but they have a QB who could hurt an already wounded Spartans secondary.

Michigan State still has to face Ohio State before ending the regular season vs. the Nittany Lions — so things aren’t going to be easy for the remainder of the schedule. Sean Clifford of PSU, CJ Stroud of OSU and Taulia Tagovailoa of Maryland are the class of the Big Ten in terms of quarterbacks.

Each of them is capable of slicing up the defensive backs just like O’Connell did for Purdue.

The Spartans gave up 383 yards to Michigan QB Cade McNamara, only to be slapped with 536 from O’Connell. There are leaks in MSU’s defensive backfield, and the past 2 games have served as warnings. MSU has to tighten up or prepare for a rough ending to the season.

The next 3 QBs on the schedule pose the biggest risk for a group of safeties and corners that has been incredibly inconsistent. It was a magical run in progress for MSU one week ago. Rivalry win, ranked in the top 4 of the CFP standings. Then boom, a loss to Purdue knocked MSU down a few notches, causing it to take a hard look at its biggest weaknesses and re-evaluate the course of the season.

Starting with the Terps, MSU basically has to push the reset button. Again, the season isn’t doomed, but Saturday was a not-so-kind reminder that the Spartans aren’t flawless. They will not survive the next 3 games if they don’t find a way to limit opposing quarterbacks.

That’s MSU’s forecast, in a nutshell, for the remainder of the year. Other QBs were close to cracking the code earlier this year. O’Connell found a way to do so. It’s safe to say that Clifford, Stroud and Tagovailoa could do the same, or worse, when they get their turns.