]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Refs #2679 added a function for processing groups plugin upgrades
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sun, 6 Mar 2011 00:07:57 +0000 (00:07 +0000)
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>
Sun, 6 Mar 2011 00:07:57 +0000 (00:07 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@8608 36083f99-b078-4883-b0ff-0f9b5a30f544

mod/groups/start.php

index f8cff6a8a5739727773ef2e3e5c9b943cbeb3e2f..1012b5bbc70ecd07a092ee392586c385a43df5bb 100644 (file)
@@ -548,7 +548,6 @@ function discussion_init() {
        register_notification_object('object', 'groupforumtopic', elgg_echo('groupforumtopic:new'));
        elgg_register_plugin_hook_handler('object:notifications', 'object', 'group_object_notifications_intercept');
        elgg_register_plugin_hook_handler('notify:entity:message', 'object', 'groupforumtopic_notify_message');
-
 }
 
 /**
@@ -718,3 +717,14 @@ function groups_can_edit_discussion($entity, $group_owner) {
                return false;
        }
 }
+
+/**
+ * Process upgrades for the groups plugin
+ */
+function groups_run_upgrades() {
+       $path = elgg_get_plugins_path() . 'groups/upgrades/';
+       $files = elgg_get_upgrade_files($path);
+       foreach ($files as $file) {
+               include "$path{$file}";
+       }
+}