source/Core/Form/FormFieldsCleaner.php
private function filterFieldsByWhiteList(\ArrayIterator $allowedFields, array $listToClean)
    {
        $allowedFieldsLowerCase = array_map('strtolower', (array)$allowedFields);
        $cleanedList = array_filter($listToClean, function ($field) use ($allowedFieldsLowerCase) {
            return in_array(strtolower($field), $allowedFieldsLowerCase);
        }, ARRAY_FILTER_USE_KEY);

        return $cleanedList;
    }
private function filterFieldsByWhiteList(\ArrayIterator $allowedFields, array $listToClean)
    {
        $allowedFieldsLowerCase = array_map('strtolower', (array)$allowedFields);
        $cleanedList = array_filter($listToClean, function ($field) use ($allowedFieldsLowerCase) {
            return in_array(strtolower($field), $allowedFieldsLowerCase);
        }, ARRAY_FILTER_USE_KEY);

        return $cleanedList;
    }
private function filterFieldsByWhiteList ( \ ArrayIterator $ allowedFields , array $ listToClean ) { $ allowedFieldsLowerCase = array_map ( 'strtolower' , ( array ) $ allowedFields ) ; $ cleanedList = array_filter ( $ listToClean , function ( $ field ) use ( $ allowedFieldsLowerCase ) { return in_array ( strtolower ( $ field ) , $ allowedFieldsLowerCase ) ; } , ARRAY_FILTER_USE_KEY ) ; return $ cleanedList ; }
Return fields by performing a case-insensitive compare.
Does not change original case-sensitivity of fields.

@param \ArrayIterator $allowedFields
@param array          $listToClean

@return array
Return fields by performing a case - insensitive compare . Does not change original case - sensitivity of fields .