When trying to import or update a Views 1 view into Views 2, currently you'll receive the error:

Fatal error: Call to a member function set_option() on a non-object in /Users/nate/Sites/drupal6/sites/all/modules/views/includes/convert.inc on line 165

This is because the import tool assumes that the default displays for both pages and blocks are named "page" and "block" respectively. At some point this changed to "page_1" and "block_1", so attempting to call methods on $view->display['page']->handler does not work.

This patch changes the default names to use those returned by $view->add_display() so that this doesn't happen again.

CommentFileSizeAuthor
views_convert_display_names.patch1.21 KBquicksketch

Comments

merlinofchaos’s picture

Status: Needs review » Fixed

Committed to -dev! Thanks for catching this!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.