Merge pull request #10719 from creative-commoners/pulls/5.0/remove-depr

API Remove deprecated code
This commit is contained in:
Guy Sartorelli 2023-03-06 14:44:33 +13:00 committed by GitHub
commit a0b3eaddc0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 0 additions and 51 deletions

View File

@ -225,47 +225,6 @@ class Convert
return html_entity_decode($val ?? '', ENT_QUOTES, 'UTF-8');
}
/**
* Convert a XML string to a PHP array recursively. Do not
* call this function directly.
*
* @param SimpleXMLElement $xml
*
* @return mixed
* @deprecated 4.11.0 Will be removed without equivalent functionality
*/
protected static function recursiveXMLToArray($xml)
{
Deprecation::notice('4.11.0', 'Will be removed without equivalent functionality');
$x = null;
if ($xml instanceof SimpleXMLElement) {
$attributes = $xml->attributes();
foreach ($attributes as $k => $v) {
if ($v) {
$a[$k] = (string) $v;
}
}
$x = $xml;
$xml = get_object_vars($xml);
}
if (is_array($xml)) {
if (count($xml ?? []) === 0) {
return (string)$x;
} // for CDATA
$r = [];
foreach ($xml as $key => $value) {
$r[$key] = self::recursiveXMLToArray($value);
}
// Attributes
if (isset($a)) {
$r['@'] = $a;
}
return $r;
}
return (string) $xml;
}
/**
* Create a link if the string is a valid URL
*

View File

@ -227,7 +227,6 @@ trait CustomMethods
*
* @param object $object
* @return array
* @deprecated 4.13.0 Will be replaced by findMethodsFrom() in CMS 5
*/
protected function findMethodsFrom($object)
{

View File

@ -19,15 +19,6 @@ class Sources implements Resettable
use Injectable;
use Configurable;
/**
* List of prioritised modules, in lowest to highest priority.
*
* @config
* @var array
* @deprecated 4.0.0 Use SilverStripe\Core\Manifest\ModuleManifest.module_priority instead
*/
private static $module_priority = [];
/**
* Get sorted modules
*