Skip to content

ref: Clean up code#2623

Merged
szokeasaurusrex merged 1 commit intomasterfrom
szokeasaurusrex/improve-readability
Jul 17, 2025
Merged

ref: Clean up code#2623
szokeasaurusrex merged 1 commit intomasterfrom
szokeasaurusrex/improve-readability

Conversation

@szokeasaurusrex
Copy link
Copy Markdown
Member

@szokeasaurusrex szokeasaurusrex commented Jul 16, 2025

It is a bit weird to have this block defining two variables inside the definition of another variable.

I think the following is a bit more readable. It also keeps the code DRY.

Review alongside #2618, this is basically the changes I would have suggested on that PR

@szokeasaurusrex szokeasaurusrex changed the title ref: Clean up weird code ref: Clean up code Jul 16, 2025
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/improve-readability branch from 0c204e4 to 501ff90 Compare July 16, 2025 14:25
@szokeasaurusrex szokeasaurusrex marked this pull request as draft July 16, 2025 14:26
It is a bit weird to have this block defining two variables inside the definition of another variable.

I think the following is a bit more readable. It also keeps the code DRY.

Should be reviewed alongside #2618
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/improve-readability branch from 501ff90 to 25708db Compare July 16, 2025 14:28
@szokeasaurusrex szokeasaurusrex marked this pull request as ready for review July 16, 2025 14:29
Copy link
Copy Markdown
Contributor

@loewenheim loewenheim left a comment

Choose a reason for hiding this comment

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

I don't mind the variables in the block, but your version is still better even so.

Copy link
Copy Markdown
Contributor

@noahsmartin noahsmartin left a comment

Choose a reason for hiding this comment

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

thanks!

@szokeasaurusrex szokeasaurusrex merged commit 504638f into master Jul 17, 2025
26 checks passed
@szokeasaurusrex szokeasaurusrex deleted the szokeasaurusrex/improve-readability branch July 17, 2025 10:40
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.

3 participants