]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/siteprofile.php
No more needed (for this fix) but maybe later. So I always only comment them out.
[quix0rs-gnu-social.git] / lib / siteprofile.php
index 16237f1bc3219744b490e7c2426996014e35a403..4bbffea7542ccd149ded02acad15b64f4762c4bb 100644 (file)
@@ -28,7 +28,7 @@
  * @link      http://status.net/
  */
 
-if (!defined('STATUSNET')) {
+if (!defined('GNUSOCIAL')) {
     exit(1);
 }
 
@@ -78,17 +78,11 @@ abstract class SiteProfileSettings
         throw new MethodNotImplementedException(__METHOD__);
     }
 
+    static function corePlugins() {
+        return common_config('plugins', 'core');
+    }
     static function defaultPlugins() {
-        return array(
-            'Bookmark'                => null,
-            'Event'                   => null,
-            'OpenID'                  => null,
-            'Poll'                    => null,
-            'QnA'                     => null,
-            'SearchSub'               => null,
-            'StrictTransportSecurity' => null,
-            'TagSub'                  => null,
-        );
+        return common_config('plugins', 'default');
     }
 }
 
@@ -114,12 +108,10 @@ class PublicSite extends SiteProfileSettings
                 )
             ),
             'plugins' => array(
+                'core'    => self::corePlugins(),
                 'default' => array_merge(self::defaultPlugins(), array(
-                    'ClientSideShorten'       => null,
-                    'Directory'               => null,
-                    'ExtendedProfile'         => null,
-                    'Geonames'                => null,
-                    'OStatus'                 => null,
+                    'ExtendedProfile'         => array(),
+                    'RegisterThrottle'        => array(),
                 ))
             ),
             'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
@@ -150,16 +142,16 @@ class PrivateSite extends SiteProfileSettings
                 )
             ),
             'plugins' => array(
+                'core'    => self::corePlugins(),
                 'default' => array_merge(self::defaultPlugins(), array(
-                    'ClientSideShorten'       => null,
-                    'Directory'               => null,
-                    'ExtendedProfile'         => null,
-                    'EmailRegistration'       => null,
-                    'Geonames'                => null,
-                    'NewMenu'                 => null,
-                    'MobileProfile'           => null,
-                ))
+                    'ExtendedProfile'         => array(),
+                    'EmailRegistration'       => array(),
+                    'MobileProfile'           => array(),
+                )),
+                'disable-OStatus' => 1,
+                'disable-WebFinger' => 1,
              ),
+            'public'        => array('localonly' => true),
             'profile'       => array('delete' => 'true'),
             'license'       => array('type'   => 'private'),
             'attachments'   => array(
@@ -199,17 +191,16 @@ class CommunitySite extends SiteProfileSettings
             'site' => array_merge(
                 $config['site'], array(
                     'private'    => false,
+                    'inviteonly' => true,
                     'closed'     => false
                 )
             ),
             'plugins' => array(
+                'core'    => self::corePlugins(),
                 'default' => array_merge(self::defaultPlugins(), array(
-                    'ClientSideShorten'       => null,
-                    'Directory'               => null,
-                    'Geonames'                => null,
-                    'OStatus'                 => null,
                 ))
             ),
+            'public'    => array('localonly' => true),
             'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
         );
     }
@@ -235,19 +226,17 @@ class SingleuserSite extends SiteProfileSettings
                 $config['site'], array(
                     'private'    => false,
                     'closed'     => true,
+                    'localonly'  => true,
                 )
             ),
             'plugins' => array(
+                'core'    => self::corePlugins(),
                 'default' => array_merge(self::defaultPlugins(), array(
-                    'ClientSideShorten'       => null,
-                    'Geonames'                => null,
-                    'NewMenu'                 => null,
-                    'MobileProfile'           => null,
-                    'OStatus'                 => null,
-                    'TwitterBridge'           => null,
-                    'FacebookBridge'          => null,
-                ))
+                    'MobileProfile'           => array(),
+                )),
+                'disable-Directory' => 1,
             ),
+            'public'    => array('localonly' => true),
             'discovery' => array('cors' => true) // Allow Cross-Origin Resource Sharing for service discovery (host-meta, XRD, etc.)
         );
     }