From eb538def799eb54e1ce29996dfbc56f4c960e3f3 Mon Sep 17 00:00:00 2001 From: brettp Date: Mon, 5 Apr 2010 22:13:53 +0000 Subject: Added category and name as valid plugin manifest keys/values. git-svn-id: http://code.elgg.org/elgg/trunk@5629 36083f99-b078-4883-b0ff-0f9b5a30f544 --- engine/lib/plugins.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'engine') diff --git a/engine/lib/plugins.php b/engine/lib/plugins.php index 4861ffd09..bc703f6c6 100644 --- a/engine/lib/plugins.php +++ b/engine/lib/plugins.php @@ -331,7 +331,11 @@ function load_plugin_manifest($plugin) { $xml = xml_to_object(file_get_contents($CONFIG->pluginspath . $plugin. "/manifest.xml")); if ($xml) { - $elements = array(); + // set up some defaults to normalize expected values to arrays + $elements = array( + 'screenshot' => array(), + 'category' => array() + ); foreach ($xml->children as $element) { $key = $element->attributes['key']; @@ -358,7 +362,7 @@ function load_plugin_manifest($plugin) { /** * This function checks a plugin manifest 'elgg_version' value against the current install - * returning TRUE if the elgg_version is <= the current install's version. + * returning TRUE if the elgg_version is >= the current install's version. * @param $manifest_elgg_version_string The build version (eg 2009010201). * @return bool */ -- cgit v1.2.3