Skip to content

mirage/crates: Return 404 if specified crate can't be found #2130

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

Merged
merged 1 commit into from
Jan 15, 2020

Conversation

Turbo87
Copy link
Member

@Turbo87 Turbo87 commented Jan 14, 2020

Our GET /api/v1/crates/:id mirage request handler was not handling unknown crates the same way as the production API server. This PR fixes the inconsistency by returning a 404 error if the client requests a crate that does not exist on the mock server.

r? @locks

@locks
Copy link
Contributor

locks commented Jan 15, 2020

@bors r+

@bors
Copy link
Contributor

bors commented Jan 15, 2020

📌 Commit 30634f7 has been approved by locks

@bors
Copy link
Contributor

bors commented Jan 15, 2020

⌛ Testing commit 30634f7 with merge cef430d...

bors added a commit that referenced this pull request Jan 15, 2020
mirage/crates: Return 404 if specified crate can't be found

Our `GET /api/v1/crates/:id` mirage request handler was not handling unknown crates the same way as the production API server. This PR fixes the inconsistency by returning a 404 error if the client requests a crate that does not exist on the mock server.

r? @locks
@bors
Copy link
Contributor

bors commented Jan 15, 2020

☀️ Test successful - checks-travis
Approved by: locks
Pushing cef430d to master...

@bors bors merged commit 30634f7 into rust-lang:master Jan 15, 2020
@Turbo87 Turbo87 deleted the 404 branch March 30, 2020 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants