reactiveui / refit

The automatic type-safe REST library for .NET Core, Xamarin and .NET. Heavily inspired by Square's Retrofit library, Refit turns your REST API into a live interface.
https://reactiveui.github.io/refit/
MIT License
8.65k stars 744 forks source link

feat: lazy initialize `queryParamsToAdd` #1907

Closed TimothyMakkison closed 2 weeks ago

TimothyMakkison commented 2 weeks ago

Lazy initializes List<KeyValuePair<string, string?>> queryParamsToAdd only when it is used.

AddQueryParameters could be updated to not create interim lists and just directly update a given list. However, with a couple of changes refit could just directly write queries into a ValueStringBuilder representing the URL.

codecov[bot] commented 2 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 84.90%. Comparing base (6ebeda5) to head (5187fa0). Report is 158 commits behind head on main.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1907 +/- ## ========================================== - Coverage 87.73% 84.90% -2.84% ========================================== Files 33 36 +3 Lines 2348 2504 +156 Branches 294 363 +69 ========================================== + Hits 2060 2126 +66 - Misses 208 299 +91 + Partials 80 79 -1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

github-actions[bot] commented 5 days ago

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.