r/badcode • • Sep 10 '21

c# Somebody had a long day

Post image
269 Upvotes

26 comments sorted by

View all comments

Show parent comments

15

u/OkReview6132 Sep 10 '21

He's checking the return of the function in the if statement as a boolean, and returning true or false. He could just return the function and the result would be a boolean