Skip to content

Conversation

@ginger51011
Copy link
Contributor

Before only the home dir could be used, this makes it a bit more ergonomic if the user has other desires.

Before only the home dir could be used, this makes it a bit more ergonomic
if the user has other desires
@ginger51011 ginger51011 changed the title Add HttpCache::in_dir constructor to allow for custom cache placement [github] Add HttpCache::in_dir constructor to allow for custom cache placement Mar 2, 2023
@augustuswm
Copy link
Contributor

Makes sense to me. Only suggestion is that in_home_dir get replaced with:

pub fn in_home_dir() -> BoxedHttpCache {
    Self::in_dir(&dirs::home_dir().expect("Expected a home dir"))
}

@ginger51011
Copy link
Contributor Author

Makes sense to me. Only suggestion is that in_home_dir get replaced with:

Good point, added that!

@augustuswm augustuswm merged commit c748ae1 into oxidecomputer:main Mar 3, 2023
kavin-kr pushed a commit to kavin-kr/third-party-api-clients that referenced this pull request Mar 28, 2023
…e placement (oxidecomputer#59)

* Add HttpCache::in_dir constructor to allow for custom cache placement

Before only the home dir could be used, this makes it a bit more ergonomic
if the user has other desires

* Use HttpCache::in_dir for HttpCache::in_home_dir
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