Skip to content

Conversation

@eth3lbert
Copy link
Contributor

This PR converts most functions in the crate_owner_invitation model to async/await and removes unnecessary spawn_blocking() usage in the controller. The create function is left unconverted due to additional work required, which I plan to address in a future PR :)

Removes `spawn_blocking()` usage from
`PUT /api/v1/me/crate_owner_invitations/:crate_id` and
`PUT /api/v1/me/crate_owner_invitations/accept/:token` endpoints.

Converts `CrateOwnerInvitation::accept()` and
`CrateOwnerInvitation::decline()` to async fns.
@codecov
Copy link

codecov bot commented Nov 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 88.99%. Comparing base (f41a3df) to head (656a233).
Report is 4 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #9890   +/-   ##
=======================================
  Coverage   88.99%   88.99%           
=======================================
  Files         290      290           
  Lines       30086    30096   +10     
=======================================
+ Hits        26776    26785    +9     
- Misses       3310     3311    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Turbo87 Turbo87 added C-internal 🔧 Category: Nonessential work that would make the codebase more consistent or clear A-backend ⚙️ labels Nov 10, 2024
@Turbo87 Turbo87 merged commit 6222bbc into rust-lang:main Nov 10, 2024
10 checks passed
@eth3lbert eth3lbert deleted the async-invitation branch November 10, 2024 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-backend ⚙️ C-internal 🔧 Category: Nonessential work that would make the codebase more consistent or clear

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants