Tax amendment or not

I had gotten a 2023 W-2 for a class-action settlement in March 2023. I then mistakenly filed it with my 2022 tax returns. The Federal return went through just fine and I paid taxes that were due. The state owed me a refund but they said they did not have a record of the state tax paid in that particular W-2. So I got a refund after the state tax in that W-2 was deducted. This was when I realized the mistake I made. The question now is that do I need to file that W-2 again with my 2023 taxes and file an amendment for 2022? Or would I be ok to leave things as is?