USEPA / StreamCatTools

R package to work with the StreamCat API within R and access the full suite of StreamCat catchment and watershed scale metrics for all NHDPlusV2 stream reaches and catchments.
https://usepa.github.io/StreamCatTools/
Creative Commons Zero v1.0 Universal
30 stars 6 forks source link

Migrate to httr2 #29

Closed zsmith27 closed 11 months ago

zsmith27 commented 1 year ago

Thank you for creating this package! I have been interested in having this capability available in R for a number of years. I made a couple suggested changes that I hope will be helpful for maintaining this package into the future.

Overview of changes:

  1. Refactored existing code to use httr2 instead of httr. Per httr documentation: "httr is superseded: only changes necessary to keep it on CRAN will be made. We recommend using httr2 instead."
  2. Refactored existing code to simplify the call for NLCD data. I removed many of the if else calls, which I think will improve readability.
mhweber commented 1 year ago

Thank you @zsmith27 ! Sorry to be slow on issues here - greatly appreciate the PR - will look over shortly!

zsmith27 commented 11 months ago

@mhweber, I just wanted to make sure you are aware that you closed this PR without merging.

mhweber commented 11 months ago

@zsmith27 , not sure how I managed to close this w/out merging! But merged now - thanks for the note!

zsmith27 commented 11 months ago

No problem. I didn't notice until earlier this week.