minor #37343 [3.4] Small update in our internal terminology (Nyholm)
This PR was merged into the 3.4 branch.
Discussion
----------
[3.4] Small update in our internal terminology
| Q | A
| ------------- | ---
| Branch? | 3.4
| Bug fix? | no
| New feature? | no
| Deprecations? | no
| Tickets | -
| License | MIT
| Doc PR | -
The part of #37128 that applies to 3.4.
Commits
-------
c143aacd81
[3.4] Small update in our internal terminology
This commit is contained in:
commit
13d5e180d2
@ -23,7 +23,7 @@ use Symfony\Component\HttpKernel\Exception\HttpException;
|
||||
*/
|
||||
class NotFoundActivationStrategy extends ErrorLevelActivationStrategy
|
||||
{
|
||||
private $blacklist;
|
||||
private $exclude;
|
||||
private $requestStack;
|
||||
|
||||
public function __construct(RequestStack $requestStack, array $excludedUrls, $actionLevel)
|
||||
@ -31,7 +31,7 @@ class NotFoundActivationStrategy extends ErrorLevelActivationStrategy
|
||||
parent::__construct($actionLevel);
|
||||
|
||||
$this->requestStack = $requestStack;
|
||||
$this->blacklist = '{('.implode('|', $excludedUrls).')}i';
|
||||
$this->exclude = '{('.implode('|', $excludedUrls).')}i';
|
||||
}
|
||||
|
||||
public function isHandlerActivated(array $record)
|
||||
@ -45,7 +45,7 @@ class NotFoundActivationStrategy extends ErrorLevelActivationStrategy
|
||||
&& 404 == $record['context']['exception']->getStatusCode()
|
||||
&& ($request = $this->requestStack->getMasterRequest())
|
||||
) {
|
||||
return !preg_match($this->blacklist, $request->getPathInfo());
|
||||
return !preg_match($this->exclude, $request->getPathInfo());
|
||||
}
|
||||
|
||||
return $isActivated;
|
||||
|
@ -136,10 +136,10 @@ class AddAnnotatedClassesToCachePass implements CompilerPassInterface
|
||||
|
||||
private function matchAnyRegexps($class, $regexps)
|
||||
{
|
||||
$blacklisted = false !== strpos($class, 'Test');
|
||||
$isTest = false !== strpos($class, 'Test');
|
||||
|
||||
foreach ($regexps as $regex) {
|
||||
if ($blacklisted && false === strpos($regex, 'Test')) {
|
||||
if ($isTest && false === strpos($regex, 'Test')) {
|
||||
continue;
|
||||
}
|
||||
|
||||
|
@ -25,7 +25,7 @@ use Symfony\Component\Intl\Data\Util\LocaleScanner;
|
||||
*/
|
||||
class CurrencyDataGenerator extends AbstractDataGenerator
|
||||
{
|
||||
private static $blacklist = [
|
||||
private static $denylist = [
|
||||
'XBA' => true, // European Composite Unit
|
||||
'XBB' => true, // European Monetary Unit
|
||||
'XBC' => true, // European Unit of Account (XBC)
|
||||
@ -136,7 +136,7 @@ class CurrencyDataGenerator extends AbstractDataGenerator
|
||||
$symbolNamePairs = iterator_to_array($rootBundle['Currencies']);
|
||||
|
||||
// Remove unwanted currencies
|
||||
$symbolNamePairs = array_diff_key($symbolNamePairs, self::$blacklist);
|
||||
$symbolNamePairs = array_diff_key($symbolNamePairs, self::$denylist);
|
||||
|
||||
return $symbolNamePairs;
|
||||
}
|
||||
|
@ -27,7 +27,7 @@ use Symfony\Component\Intl\Data\Util\LocaleScanner;
|
||||
*/
|
||||
class RegionDataGenerator extends AbstractDataGenerator
|
||||
{
|
||||
private static $blacklist = [
|
||||
private static $denylist = [
|
||||
// Look like countries, but are sub-continents
|
||||
'QO' => true, // Outlying Oceania
|
||||
'EU' => true, // European Union
|
||||
@ -50,7 +50,7 @@ class RegionDataGenerator extends AbstractDataGenerator
|
||||
|
||||
public static function isValidCountryCode($region)
|
||||
{
|
||||
if (isset(self::$blacklist[$region])) {
|
||||
if (isset(self::$denylist[$region])) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user