134

I have no idea why he doing this ._.

Comments
  • 11
    Ahahaha great stuff hope that's passing a test somewhere
  • 9
    The hell does that even mean?
  • 6
    That coder must be chuck norris cousin
  • 3
    //Not only is this stupid, it's mixing

    if ("foo")
    {
    return true;
    }

    //and

    if ("bar") {
    return false;
    }

    // I can't even
  • 1
    XD LITπŸ‘Œ
  • 9
    Maybe he was never taught that return statement can be outside an if block...
    ...And if only need a value
    ...And comparisson can be done without strings
  • 10
    Is that curly on line 552 bothering anyone else? Seems like you've got inconsistent formatting too.
  • 0
    Dat troll
  • 1
    I mean, I've actually seen this sort of awfulness lots in legacy code where people were too lazy to remove the if logic that was there and just changed it to always pass or fail. You know, because just removing it would be terrible πŸ€”
  • 2
    What I've learned from snippets like these is that never, NEVER remove it. Whatever it does it makes the code to work, and the code feels complete inside with this useless snippet in it, thus removing it is like taking a piece out of the poor code's hearth, which will makes it sad, resulting in a failed build.

    I guess I should sleep instead of commenting.
  • 1
    I've actually seen true/false defined in a database table and mapped to 0/1...

    I guess it's there in case we want to swap realities of define a 0.5 true or something...
  • 0
    I remember this code, oh God. sql api...πŸ˜‘πŸ˜‘
  • 1
    @jackgreen wohoo you're right ! Are you make this code?
  • 0
    It's obvious, to make sure it's false.
  • 0
    Sometimes, I feel like I've got a long wayyy to go before I could say I'm a real programmer and then I see shit like this that I would never do, even not knowing a language and think fuck...
Add Comment