Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b337f7c

Browse files
minor #30382 Fix git diff marker (shyim)
This PR was merged into the 4.2 branch. Discussion ---------- Fix git diff marker | Q | A | ------------- | --- | Branch? | 4.2 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | #.. | License | MIT | Doc PR | There are some git diff marker :) Commits ------- d631bd9 Fix git diff marker
2 parents e73f70a + d631bd9 commit b337f7c

File tree

1 file changed

+0
-75
lines changed

1 file changed

+0
-75
lines changed

src/Symfony/Component/HttpFoundation/Request.php

Lines changed: 0 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -617,81 +617,6 @@ public static function getTrustedHosts()
617617
}
618618

619619
/**
620-
<<<<<<< HEAD
621-
=======
622-
* Sets the name for trusted headers.
623-
*
624-
* The following header keys are supported:
625-
*
626-
* * Request::HEADER_CLIENT_IP: defaults to X-Forwarded-For (see getClientIp())
627-
* * Request::HEADER_CLIENT_HOST: defaults to X-Forwarded-Host (see getHost())
628-
* * Request::HEADER_CLIENT_PORT: defaults to X-Forwarded-Port (see getPort())
629-
* * Request::HEADER_CLIENT_PROTO: defaults to X-Forwarded-Proto (see getScheme() and isSecure())
630-
* * Request::HEADER_FORWARDED: defaults to Forwarded (see RFC 7239)
631-
*
632-
* Setting an empty value allows to disable the trusted header for the given key.
633-
*
634-
* @param string $key The header key
635-
* @param string $value The header name
636-
*
637-
* @throws \InvalidArgumentException
638-
*
639-
* @deprecated since version 3.3, to be removed in 4.0. Use the $trustedHeaderSet argument of the Request::setTrustedProxies() method instead.
640-
*/
641-
public static function setTrustedHeaderName($key, $value)
642-
{
643-
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the $trustedHeaderSet argument of the Request::setTrustedProxies() method instead.', __METHOD__), E_USER_DEPRECATED);
644-
645-
if ('forwarded' === $key) {
646-
$key = self::HEADER_FORWARDED;
647-
} elseif ('client_ip' === $key) {
648-
$key = self::HEADER_CLIENT_IP;
649-
} elseif ('client_host' === $key) {
650-
$key = self::HEADER_CLIENT_HOST;
651-
} elseif ('client_proto' === $key) {
652-
$key = self::HEADER_CLIENT_PROTO;
653-
} elseif ('client_port' === $key) {
654-
$key = self::HEADER_CLIENT_PORT;
655-
} elseif (!\array_key_exists($key, self::$trustedHeaders)) {
656-
throw new \InvalidArgumentException(sprintf('Unable to set the trusted header name for key "%s".', $key));
657-
}
658-
659-
self::$trustedHeaders[$key] = $value;
660-
661-
if (null !== $value) {
662-
self::$trustedHeaderNames[$key] = $value;
663-
self::$trustedHeaderSet |= $key;
664-
} else {
665-
self::$trustedHeaderSet &= ~$key;
666-
}
667-
}
668-
669-
/**
670-
* Gets the trusted proxy header name.
671-
*
672-
* @param string $key The header key
673-
*
674-
* @return string The header name
675-
*
676-
* @throws \InvalidArgumentException
677-
*
678-
* @deprecated since version 3.3, to be removed in 4.0. Use the Request::getTrustedHeaderSet() method instead.
679-
*/
680-
public static function getTrustedHeaderName($key)
681-
{
682-
if (2 > \func_num_args() || func_get_arg(1)) {
683-
@trigger_error(sprintf('The "%s()" method is deprecated since Symfony 3.3 and will be removed in 4.0. Use the Request::getTrustedHeaderSet() method instead.', __METHOD__), E_USER_DEPRECATED);
684-
}
685-
686-
if (!\array_key_exists($key, self::$trustedHeaders)) {
687-
throw new \InvalidArgumentException(sprintf('Unable to get the trusted header name for key "%s".', $key));
688-
}
689-
690-
return self::$trustedHeaders[$key];
691-
}
692-
693-
/**
694-
>>>>>>> 3.4
695620
* Normalizes a query string.
696621
*
697622
* It builds a normalized query string, where keys/value pairs are alphabetized,

0 commit comments

Comments
 (0)