Skip to content
This repository has been archived by the owner on Jul 17, 2023. It is now read-only.

Commit

Permalink
[feat] failed dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
icepuma committed Dec 5, 2018
1 parent 5c105b9 commit 2267406
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/problem.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ impl Problem {
Self::for_status(405, "Method not allowed")
}

pub fn failed_dependency() -> Problem {
Self::for_status(424, "Failed dependency")
}

pub fn with_details<T: std::fmt::Display>(mut self, details: T) -> Problem {
self.details = match self.details {
Some(existing) => Some(format!("{}: {}", existing, details)),
Expand Down

0 comments on commit 2267406

Please sign in to comment.