8000 chore: enable early-return from revive by mmorel-35 · Pull Request #16007 · prometheus/prometheus · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

chore: enable early-return from revive #16007

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 11, 2025

Conversation

mmorel-35
Copy link
Contributor

Description

early-return: In Go it is idiomatic to minimize nesting statements, a typical example is to avoid if-then-else constructions.

Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
Copy link
Member
@beorn7 beorn7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it, and I think it's uncontroversial.

We can still revert if I'm mistaken. ;)

@beorn7 beorn7 merged commit 13c05a3 into prometheus:main Feb 11, 2025
26 checks passed
@mmorel-35 mmorel-35 deleted the revive/early-return branch February 11, 2025 19:47
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
0