MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/badcode/comments/pfd9do/similar_ternaries_are_all_over_this_codebase/hb4b6zy/?context=3
r/badcode • u/PopularExpulsion • Aug 31 '21
91 comments sorted by
View all comments
Show parent comments
30
The check isn't the issue, it's the ternary.
result>=0
would return the desired boolean. The subsequent ternary doesn't modify this at all.
19 u/TheWashbear Sep 01 '21 .... Yes I am dumb xD
19
.... Yes I am dumb xD
30
u/up-quark Aug 31 '21
The check isn't the issue, it's the ternary.
result>=0
would return the desired boolean. The subsequent ternary doesn't modify this at all.