Frigidaire front load washer will not spin

I have a question for awhile my cloths kept smelling like mold , I was wondering if anyone else ever had this problem. I did leave door open and dry door and inside and it kept getting worse, finally I used vinegar thru the washer and bought those deodorant packets to run thru it haven’t had this problem now but I was wondering if anyone has other thoughts on what I can do or if anyone else can help. Thank u :smiley: :eek: