mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #8722 from lerni/fix-Warning]-on-count()-with-PHP->=-7.2
fix [Warning] on count() with PHP >= 7.2
This commit is contained in:
commit
1c18d9505f
@ -446,7 +446,7 @@ class Versioned extends DataExtension implements TemplateGlobalProvider {
|
||||
|
||||
// Build a list of suffixes whose tables need versioning
|
||||
$allSuffixes = array();
|
||||
$versionableExtensions = $this->owner->config()->versionableExtensions;
|
||||
$versionableExtensions = (array)$this->owner->config()->versionableExtensions;
|
||||
if(count($versionableExtensions)){
|
||||
|
||||
foreach ($versionableExtensions as $versionableExtension => $suffixes) {
|
||||
@ -936,7 +936,7 @@ class Versioned extends DataExtension implements TemplateGlobalProvider {
|
||||
* @return string
|
||||
*/
|
||||
public function extendWithSuffix($table) {
|
||||
$versionableExtensions = $this->owner->config()->versionableExtensions;
|
||||
$versionableExtensions = (array)$this->owner->config()->versionableExtensions;
|
||||
|
||||
if(count($versionableExtensions)){
|
||||
foreach ($versionableExtensions as $versionableExtension => $suffixes) {
|
||||
|
Loading…
Reference in New Issue
Block a user