Best to replace as is a safety issue. However, mine has been unplugged since the wire melted due to the bad sensor, which only went bad cause of the hissing sound from my brake pedal. So with a spongy pedal telling the sensor to tell me I have an issue. I don't know about you but I like to stop when I need to and I will be ensuring all my parts are replaced and in good working order before I go far.
With that said, I have been driving it for about a year like that, so you could still drive it, as you have been anyways. So once it's replaced you shouldn't have to worry about it and thats peace of mind.