Skip to content

Conversation

@cadmic
Copy link
Collaborator

@cadmic cadmic commented May 22, 2025

for instances of

if (cond && !func(...)) {
    return false;
}

where cond is a "check something" thing and func is a "do something" thing, rewrite this as

if (cond) {
    if (!func(...)) {
        return false;
    }
}

I find this easier to read since the if (!func(...)) return false; is standard boilerplate and isn't really part of the condition.

@Yanis002 Yanis002 merged commit ce7cba2 into zeldaret:main May 22, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants