1
0
mirror of https://github.com/fafhrd91/actix-web synced 2024-11-28 01:52:57 +01:00

make mut api private

This commit is contained in:
Nikolay Kim 2018-06-18 01:03:07 +06:00
parent 9d114d785e
commit daed502ee5

View File

@ -265,7 +265,7 @@ impl<S> HttpRequest<S> {
/// ///
///This is intended to be used by middleware. ///This is intended to be used by middleware.
#[inline] #[inline]
pub fn headers_mut(&mut self) -> &mut HeaderMap { pub(crate) fn headers_mut(&mut self) -> &mut HeaderMap {
&mut self.as_mut().headers &mut self.as_mut().headers
} }
@ -450,7 +450,7 @@ impl<S> HttpRequest<S> {
/// Get mutable reference to request's Params. /// Get mutable reference to request's Params.
#[inline] #[inline]
pub fn match_info_mut(&mut self) -> &mut Params { pub(crate) fn match_info_mut(&mut self) -> &mut Params {
unsafe { mem::transmute(&mut self.as_mut().params) } unsafe { mem::transmute(&mut self.as_mut().params) }
} }