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

FileService: remove OptionT from inner methods. #2555

Merged

Conversation

@diesalbla
Copy link
Contributor

commented May 5, 2019

In the inner methods getPartialContentFile and getFile, the OptionT wrapper serves no purpose, since no special method is used. We remove its from those functions, and put it in the call places, where they are actually used.

FileService: remove OptionT from inner methods.
In the inner methods `getPartialContentFile` and `getFile`, the
OptionT wrapper is serving no purpose, since no special method is
used. We therefore move their use to the call places, which is
where the OptionT methods are actually used.

@diesalbla diesalbla force-pushed the diesalbla:FileService_getPartialContentFile branch from 72165a0 to 9018d8a May 5, 2019

@rossabaker
Copy link
Member

left a comment

Lukewarm 👍. It gets a slight amount of pure code (the .get(Range)) out of the sync context and saves a couple allocations in code where the file system access will dominate anyway.

@rossabaker rossabaker merged commit 2c0507d into http4s:master May 28, 2019

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@diesalbla diesalbla deleted the diesalbla:FileService_getPartialContentFile branch May 30, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.