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 duplicate code #13

Merged
merged 3 commits into from
Dec 21, 2019
Merged

Conversation

lfos
Copy link
Contributor

@lfos lfos commented Dec 18, 2019

Three patches to remove a few instances of duplicate code.

lfos added 3 commits December 18, 2019 12:59
This function is really just a wrapper around produceOutput(). While
currently, all parameters are constant strings, there's no real reason
to hardcode the format string in waitThenAction() anymore. As a bonus,
this small change allows us to get rid of the cost of formatting a few
extra strings.
These functions are almost identical. No need to reimplement the same
thing twice.
The pointer s is obtained from sessions[sessionId] and is never changed
within this function. No need to reassign s to sessions[sessionId].
@lfos lfos force-pushed the remove-duplicate-code branch from db2d7f8 to 14d2a9c Compare December 18, 2019 18:01
@lfos lfos mentioned this pull request Dec 19, 2019
@poolpOrg
Copy link
Owner

reads fine, will test shortly and merge

@poolpOrg poolpOrg merged commit feefb2f into poolpOrg:master Dec 21, 2019
@lfos lfos deleted the remove-duplicate-code branch December 22, 2019 22: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.

2 participants