Put a DVM on the fuse panel to see if you are getting a signal when the switch is activated, if not replace the relay. If relay does not correct it then the switch may be faulty or corrosion build up and simple clean may take care of it.
When you turn the hazards on, is it normal? this will eliminate the light assembly issues. My driver rear turn signal was intermittent, I found the PCB type part of the socket was fractured and the hot lead was shorting out. JB welded and it is good as new

In fact I checked all the sockets and found my passenger side brake light socket PCB was fractured too
Jim