mirror of
https://github.com/actix/actix-web.git
synced 2025-02-22 13:56:19 +00:00
Data::into_inner
This commit is contained in:
parent
61e492e7e3
commit
a07cdd6533
2 changed files with 7 additions and 0 deletions
|
@ -8,6 +8,8 @@
|
||||||
|
|
||||||
* Form immplements Responder, returning a `application/x-www-form-urlencoded` response
|
* Form immplements Responder, returning a `application/x-www-form-urlencoded` response
|
||||||
|
|
||||||
|
* Add `into_inner` to `Data`
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
||||||
* `Query` payload made `pub`. Allows user to pattern-match the payload.
|
* `Query` payload made `pub`. Allows user to pattern-match the payload.
|
||||||
|
|
|
@ -77,6 +77,11 @@ impl<T> Data<T> {
|
||||||
pub fn get_ref(&self) -> &T {
|
pub fn get_ref(&self) -> &T {
|
||||||
self.0.as_ref()
|
self.0.as_ref()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Convert to the internal Arc<T>
|
||||||
|
pub fn into_inner(self) -> Arc<T> {
|
||||||
|
self.0
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<T> Deref for Data<T> {
|
impl<T> Deref for Data<T> {
|
||||||
|
|
Loading…
Reference in a new issue