Plugins should be initialized with an empty array, not null
This commit is contained in:
parent
b6f5f58f1a
commit
450ae3043b
|
@ -293,9 +293,9 @@ $default =
|
||||||
array('disabled' => true),
|
array('disabled' => true),
|
||||||
'plugins' =>
|
'plugins' =>
|
||||||
array('core' => array(
|
array('core' => array(
|
||||||
'AuthCrypt' => null,
|
'AuthCrypt' => array(),
|
||||||
'LRDD' => null,
|
'LRDD' => array(),
|
||||||
'StrictTransportSecurity' => null,
|
'StrictTransportSecurity' => array(),
|
||||||
),
|
),
|
||||||
'default' => array(
|
'default' => array(
|
||||||
'Activity' => array(),
|
'Activity' => array(),
|
||||||
|
|
|
@ -110,10 +110,10 @@ class PublicSite extends SiteProfileSettings
|
||||||
'plugins' => array(
|
'plugins' => array(
|
||||||
'core' => self::corePlugins(),
|
'core' => self::corePlugins(),
|
||||||
'default' => array_merge(self::defaultPlugins(), array(
|
'default' => array_merge(self::defaultPlugins(), array(
|
||||||
'Directory' => null,
|
'Directory' => array(),
|
||||||
'ExtendedProfile' => null,
|
'ExtendedProfile' => array(),
|
||||||
'OStatus' => null,
|
'OStatus' => array(),
|
||||||
'WebFinger' => null,
|
'WebFinger' => array(),
|
||||||
))
|
))
|
||||||
),
|
),
|
||||||
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
||||||
|
@ -146,10 +146,10 @@ class PrivateSite extends SiteProfileSettings
|
||||||
'plugins' => array(
|
'plugins' => array(
|
||||||
'core' => self::corePlugins(),
|
'core' => self::corePlugins(),
|
||||||
'default' => array_merge(self::defaultPlugins(), array(
|
'default' => array_merge(self::defaultPlugins(), array(
|
||||||
'Directory' => null,
|
'Directory' => array(),
|
||||||
'ExtendedProfile' => null,
|
'ExtendedProfile' => array(),
|
||||||
'EmailRegistration' => null,
|
'EmailRegistration' => array(),
|
||||||
'MobileProfile' => null,
|
'MobileProfile' => array(),
|
||||||
))
|
))
|
||||||
),
|
),
|
||||||
'profile' => array('delete' => 'true'),
|
'profile' => array('delete' => 'true'),
|
||||||
|
@ -197,9 +197,9 @@ class CommunitySite extends SiteProfileSettings
|
||||||
'plugins' => array(
|
'plugins' => array(
|
||||||
'core' => self::corePlugins(),
|
'core' => self::corePlugins(),
|
||||||
'default' => array_merge(self::defaultPlugins(), array(
|
'default' => array_merge(self::defaultPlugins(), array(
|
||||||
'Directory' => null,
|
'Directory' => array(),
|
||||||
'OStatus' => null,
|
'OStatus' => array(),
|
||||||
'WebFinger' => null,
|
'WebFinger' => array(),
|
||||||
))
|
))
|
||||||
),
|
),
|
||||||
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
||||||
|
@ -232,11 +232,11 @@ class SingleuserSite extends SiteProfileSettings
|
||||||
'plugins' => array(
|
'plugins' => array(
|
||||||
'core' => self::corePlugins(),
|
'core' => self::corePlugins(),
|
||||||
'default' => array_merge(self::defaultPlugins(), array(
|
'default' => array_merge(self::defaultPlugins(), array(
|
||||||
'MobileProfile' => null,
|
'MobileProfile' => array(),
|
||||||
'OStatus' => null,
|
'OStatus' => array(),
|
||||||
'TwitterBridge' => null,
|
'TwitterBridge' => array(),
|
||||||
'FacebookBridge' => null,
|
'FacebookBridge' => array(),
|
||||||
'WebFinger' => null,
|
'WebFinger' => array(),
|
||||||
))
|
))
|
||||||
),
|
),
|
||||||
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
|
||||||
|
|
|
@ -205,6 +205,8 @@ class StatusNet
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: We should be able to avoid this is_null and assume $params
|
||||||
|
// is an array, since that's how it is typed in addPlugin
|
||||||
if (is_null($params)) {
|
if (is_null($params)) {
|
||||||
self::addPlugin($name);
|
self::addPlugin($name);
|
||||||
} else if (is_array($params)) {
|
} else if (is_array($params)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user