From 065140400018dec28ed82fd31a754c94b7b87521 Mon Sep 17 00:00:00 2001
From: Craig Andrews <candrews@integralblue.com>
Date: Thu, 28 Jan 2010 16:08:42 -0500
Subject: [PATCH] Add backwards compatibility for the XMPP configuration before
 XMPP was made into a plugin

---
 lib/statusnet.php | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/lib/statusnet.php b/lib/statusnet.php
index beeb26cccd..2654ba5736 100644
--- a/lib/statusnet.php
+++ b/lib/statusnet.php
@@ -274,7 +274,6 @@ class StatusNet
         }
 
         // Backwards compatibility
-
         if (array_key_exists('memcached', $config)) {
             if ($config['memcached']['enabled']) {
                 addPlugin('Memcache', array('servers' => $config['memcached']['server']));
@@ -284,6 +283,21 @@ class StatusNet
                 $config['cache']['base'] = $config['memcached']['base'];
             }
         }
+        if (array_key_exists('xmpp', $config)) {
+            if ($config['xmpp']['enabled']) {
+                addPlugin('xmpp', array(
+                    'server' => $config['xmpp']['server'],
+                    'port' => $config['xmpp']['port'],
+                    'user' => $config['xmpp']['user'],
+                    'resource' => $config['xmpp']['resource'],
+                    'encryption' => $config['xmpp']['encryption'],
+                    'password' => $config['xmpp']['password'],
+                    'host' => $config['xmpp']['host'],
+                    'debug' => $config['xmpp']['debug'],
+                    'public' => $config['xmpp']['public']
+                ));
+            }
+        }
     }
 }
 
-- 
2.39.5