Permalink
Browse files

Update commons_core views exports for compatibility with VBO 6.x-1.11…

…. Moving implementation of hook_strongarm_alter into .module where it belongs.
  • Loading branch information...
ezra-g committed Sep 26, 2011
1 parent 92f2e94 commit 2218c5214a60c51158f37872624adb6dd4369880
@@ -13,28 +13,6 @@ function commons_core_ctools_plugin_api() {
}
}
-/**
- * Implementation of hook_strongarm_alter().
- */
-function commons_core_strongarm_alter(&$items) {
- $commons_tags_vid = variable_get('commons_tags_vid', 1);
- // If these variables are set but the Commons tags vid isn't 1,
- // changing the value isn't sufficient: we need to
- // create a different variable for each one.
- if (isset($items['tagging_inject_1']) && $commons_tags_vid != 1) {
- $new_item = $items['tagging_inject_1'];
- unset($items['tagging_inject_1']);
- $new_item->name = 'tagging_inject_' . $commons_tags_vid;
- $items['tagging_inject_' . $commons_tags_vid] = $new_item;
- }
- if (isset($items['tagadelic_block_tags_1']) && $commons_tags_vid !=1) {
- $new_item = $items['tagadelic_block_tags_1'];
- unset($items['tagadelic_block_tags_1']);
- $new_item->name = 'tagadelic_block_tags_' . $commons_tags_vid;
- $items['tagadelic_block_tags_' . $commons_tags_vid] = $new_item;
- }
-}
-
/**
* Implementation of hook_imagecache_default_presets().
*/
@@ -234,6 +234,28 @@ function commons_core_theme() {
return $registry;
}
+/**
+** Implementation of hook_strongarm_alter().
+**/
+function commons_core_strongarm_alter(&$items) {
+ $commons_tags_vid = variable_get('commons_tags_vid', 1);
+ // If these variables are set but the Commons tags vid isn't 1,
+ // changing the value isn't sufficient: we need to
+ // create a different variable for each one.
+ if (isset($items['tagging_inject_1']) && $commons_tags_vid != 1) {
+ $new_item = $items['tagging_inject_1'];
+ unset($items['tagging_inject_1']);
+ $new_item->name = 'tagging_inject_' . $commons_tags_vid;
+ $items['tagging_inject_' . $commons_tags_vid] = $new_item;
+ }
+ if (isset($items['tagadelic_block_tags_1']) && $commons_tags_vid !=1) {
+ $new_item = $items['tagadelic_block_tags_1'];
+ unset($items['tagadelic_block_tags_1']);
+ $new_item->name = 'tagadelic_block_tags_' . $commons_tags_vid;
+ $items['tagadelic_block_tags_' . $commons_tags_vid] = $new_item;
+ }
+}
+
/**
* Implementation of hook_og()
*/
Oops, something went wrong.

0 comments on commit 2218c52

Please sign in to comment.