Skip to content
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

Remove redundant check in pg_ResizeEventWatch #2487

Conversation

Starbuck5
Copy link
Member

@Starbuck5 Starbuck5 commented Oct 2, 2023

Two locations were checking if window == pygame_window, which isn't necessary, because on line 707 (line 694 above this diff for some reason) the function returns early if window != pygame_window

Diff looks complex because code got dedented one level after the redundant check was removed.

Two locations were checking if `window == pygame_window`, which isn't necessary, because on line 707 the function returns early if `window != pygame_window`
@Starbuck5 Starbuck5 requested a review from a team as a code owner October 2, 2023 06:26
@Starbuck5 Starbuck5 added Code quality/robustness Code quality and resilience to changes display pygame.display labels Oct 2, 2023
Copy link
Member

@ankith26 ankith26 left a comment

Choose a reason for hiding this comment

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

LGTM thanks for the PR 🎉

@ankith26 ankith26 added this to the 2.4.0 milestone Oct 2, 2023
Copy link
Member

@zoldalma999 zoldalma999 left a comment

Choose a reason for hiding this comment

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

LGTM, nice cleanups

@zoldalma999 zoldalma999 merged commit eaeadb0 into pygame-community:main Oct 2, 2023
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code quality/robustness Code quality and resilience to changes display pygame.display
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants