public function handleRequest(RequestInterface $request, callable $next)
    {
        $this->setUri($request->getUri()->getPath());
        $this->setMethod(strtoupper($request->getMethod()));
        $this->setEntityBody($request->getBody()->__toString());

        $header = $this->getHeader();
        if (null !== $header) {
            $request = $request->withHeader('Authorization', $header);
        }

        return $next($request);
    }
public function handleRequest(RequestInterface $request, callable $next)
    {
        $this->setUri($request->getUri()->getPath());
        $this->setMethod(strtoupper($request->getMethod()));
        $this->setEntityBody($request->getBody()->__toString());

        $header = $this->getHeader();
        if (null !== $header) {
            $request = $request->withHeader('Authorization', $header);
        }

        return $next($request);
    }
public function handleRequest ( RequestInterface $ request , callable $ next ) { $ this -> setUri ( $ request -> getUri ( ) -> getPath ( ) ) ; $ this -> setMethod ( strtoupper ( $ request -> getMethod ( ) ) ) ; $ this -> setEntityBody ( $ request -> getBody ( ) -> __toString ( ) ) ; $ header = $ this -> getHeader ( ) ; if ( null !== $ header ) { $ request = $ request -> withHeader ( 'Authorization' , $ header ) ; } return $ next ( $ request ) ; }
Populates uri, method and entityBody used to generate the Authentication header using the specified request object.
Appends the Authentication header if it is present and has been able to be calculated.
Populates uri method and entityBody used to generate the Authentication header using the specified request object . Appends the Authentication header if it is present and has been able to be calculated .