If it won't switch on from cold, its unlikely to be a thermal switch.
Possibly the switch is failing or possibly the cable is damaged - likely where it enters the machine or leaves the plug. Waggling the cable at the suspect end may show up a fault.
fdsafdsa, October 2017