Skip to content
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

Allow per-crate max upload sizes #218

Merged
merged 1 commit into from
Nov 19, 2015
Merged

Allow per-crate max upload sizes #218

merged 1 commit into from
Nov 19, 2015

Conversation

alexcrichton
Copy link
Member

There's still a global limit on the nginx server but each crate can now have its
own maximum limit as well which is larger than the standard limit.

Closes #40
Closes #195

let max = krate.max_upload_size.map(|m| m as u64)
.unwrap_or(app.config.max_upload_size);
if length > max {
println!("guth");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this could be slightly more... eloquent?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oops

There's still a global limit on the nginx server but each crate can now have its
own maximum limit as well which is larger than the standard limit.

Closes #40
Closes #195
alexcrichton added a commit that referenced this pull request Nov 19, 2015
Allow per-crate max upload sizes
@alexcrichton alexcrichton merged commit e739a51 into master Nov 19, 2015
@alexcrichton alexcrichton deleted the max-crate-size branch November 19, 2015 01:34
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