mirror of https://github.com/rwf2/Rocket.git
Rename JSON::unwrap() to JSON::into_inner().
This commit is contained in:
parent
c6f8b251cb
commit
b164da1a01
|
@ -58,9 +58,9 @@ impl<T> JSON<T> {
|
|||
/// # use rocket_contrib::JSON;
|
||||
/// let string = "Hello".to_string();
|
||||
/// let my_json = JSON(string);
|
||||
/// assert_eq!(my_json.unwrap(), "Hello".to_string());
|
||||
/// assert_eq!(my_json.into_inner(), "Hello".to_string());
|
||||
/// ```
|
||||
pub fn unwrap(self) -> T {
|
||||
pub fn into_inner(self) -> T {
|
||||
self.0
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue