original_string: protected function encodeCookies(Response $response)
      {
          $cookies = $response->getCookieCollection();
          foreach ($cookies as $cookie) {
              if (in_array($cookie->getName(), $this->cookieNames, true)) {
                  $value = $this->_encrypt($cookie->getValue(), $this->cipherType);
                  $response = $response->withCookie($cookie->withValue($value));
              }
          }
  
          return $response;
      }
code: protected function encodeCookies(Response $response)
      {
          $cookies = $response->getCookieCollection();
          foreach ($cookies as $cookie) {
              if (in_array($cookie->getName(), $this->cookieNames, true)) {
                  $value = $this->_encrypt($cookie->getValue(), $this->cipherType);
                  $response = $response->withCookie($cookie->withValue($value));
              }
          }
  
          return $response;
      }
code_tokens: protected function encodeCookies ( Response $ response ) { $ cookies = $ response -> getCookieCollection ( ) ; foreach ( $ cookies as $ cookie ) { if ( in_array ( $ cookie -> getName ( ) , $ this -> cookieNames , true ) ) { $ value = $ this -> _encrypt ( $ cookie -> getValue ( ) , $ this -> cipherType ) ; $ response = $ response -> withCookie ( $ cookie -> withValue ( $ value ) ) ; } } return $ response ; }
docstring: Encode cookies from a response's CookieCollection.
  
  @param \Cake\Http\Response $response The response to encode cookies in.
  @return \Cake\Http\Response Updated response with encoded cookies.
docstring_tokens: Encode cookies from a response s CookieCollection .