After installing node_export the VBO action was not showing even though there was a hook_action_info() call. In looking at the code I noticed a small error on line 264 where it checks the selected formats. Patch to follow.

Files: 

Comments

joel_osc’s picture

Here is a one liner patch.

joel_osc’s picture

Status:Active» Needs review

Setting to needs review.

lauranwv’s picture

Having same issue, Joel. I'm a developer plebeian. Could you please provide some specifics as to which module file this patch should be pasted into? It's not apparent to me.

joel_osc’s picture

The patch file is good for providing this info:

diff --git a/node_export.module b/node_export.module
index 8bdadb9..dca1708 100755
--- a/node_export.module
+++ b/node_export.module
@@ -261,7 +261,7 @@ function node_export_action_info() {
     $selected_formats = variable_get('node_export_format', array('drupal'));
     $format_handlers = node_export_format_handlers();
     foreach ($format_handlers as $format_handler => $format) {
-      if (!empty($selected_formats[$format_handler])) {
+      if (in_array($format_handler, $selected_formats)) {
          // @todo: should formats be able to define their own actions?
          if (!empty($format['#file']) && is_file($format['#file'])) {
            require_once $format['#file'];

This patch file indicates the node_export.module file is the one requiring patching and then shows the one line which was removed (-) and then the line which was added (+) in its place. You can go here to see how to apply a patch: http://drupal.org/patch/apply.

You may need to flush caches after this is done, then re-edit your view and the action should now be available in the Bulk Operations field. If you don't know how to flush caches I would install the devel module - it is most helpful.

Cheers.

bjcullinan’s picture

Issue summary:View changes

This is a perfect example of why Drupal is the most awful software ever. Why isn't this patch implemented in the latest version?