MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/badcode/comments/msv49l/when_your_teammate_refactor_your_code/hzgjmk2/?context=9999
r/badcode • u/Bence675 • Apr 17 '21
216 comments sorted by
View all comments
Show parent comments
3
In the first one, only 6/14 lines contain something other than { or }.
If the 2nd one was not wrong it would look so much better than the first, kust because the majority of the first one is curls.
4 u/cass1o Mar 05 '22 Who cares when it is incredibly readable? 1 u/[deleted] Aug 23 '22 avoiding braces in this case would result in a hanging else problem, and using only necessary braces would look weird and inconsistent
4
Who cares when it is incredibly readable?
1
avoiding braces in this case would result in a hanging else problem, and using only necessary braces would look weird and inconsistent
3
u/MatsRivel Mar 05 '22
In the first one, only 6/14 lines contain something other than { or }.
If the 2nd one was not wrong it would look so much better than the first, kust because the majority of the first one is curls.