3 ms·
It depends. Are you touching the code because you need to fix a bug in it? If so, then yes. If you need to maintain this piece of code then you might as well
by steve8918 14y ago
It depends.
Are you touching the code because you need to fix a bug in it? If so, then yes.
If you need to maintain this piece of code then you might as well fix it to the best of your ability and knowledge, but please be careful.
Are you touching the code because you came across it, and you don't like how it looks? If so, then no.
It's a shame that unreadable code exists, but you can't save the world. My mom used to tell me "Don't sit in someone else's pile of shit." Meaning, if someone else made a mess, and if you're the last person to touch it, you're going to look like the one who did it. There are bigger fish to fry in any software project than shitty-code-that-hasn't-been-touched-in-a-while-that-works.