It depends on the amount of time I'm given. If I have enough time left from another task or am being told to refactor, I'll refactor it.
If it's just badly formatted, a quick Ctrl+Alt+L (PHPStorm Shortcut for reformatting code) only takes a minute.
Only if it's really bad and/or potentially dangerous. I'm always asking other devs about dirty code, but in a nice non-confrontational way.
PS: I really like refactoring code, it's like house cleaning, makes you feel better afterwards.
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
It depends on the amount of time I'm given. If I have enough time left from another task or am being told to refactor, I'll refactor it.
If it's just badly formatted, a quick Ctrl+Alt+L (PHPStorm Shortcut for reformatting code) only takes a minute.
Only if it's really bad and/or potentially dangerous. I'm always asking other devs about dirty code, but in a nice non-confrontational way.
PS: I really like refactoring code, it's like house cleaning, makes you feel better afterwards.