Hi,

I'm getting a fatal error when I create any type of new nodes with metatag + seo_ui. Disabling seo_ui fixes the problem.

Recoverable fatal error: Argument 2 passed to metatag_filter_values_from_defaults() must be an array, null given, called in modules/metatag/metatag.module on line 545 and defined in metatag_filter_values_from_defaults() (line 925 of modules/metatag/metatag.module).

I'm using

  • metatag-7.x-1.0-alpha4
  • seo_ui-7.x-1.0

In a blank Drupal install (Minimal installation profile). I have also tested with the -dev branches of each module with the same result.

Any ideas? It seems like it's probably some issue with an extra array getting added when the metatag fieldset got put in another fieldset. Thanks!

Comments

builderShawn’s picture

Also getting this error.

amaria’s picture

I haven't seen this error but before I do, was there anything in particular you filled out in the Meta tags that triggers the error? Or did you just save a node with title?

jlyon’s picture

I just saved a node with title.

amaria’s picture

Status: Active » Needs review
StatusFileSize
new705 bytes

Ok, I finally was able to reproduce this. I had to disable the OpenGraph module included with this project. The bug was in the form_alter hook where the submit handler is replaced. This patch should fix the error.

PatchRanger’s picture

Indeed, I had the same issue : while creating or updating nodes with module seo_ui enabled exact the same message appears ("Recoverable fatal error: Argument 2 passed to metatag_filter_values_from_defaults() must be an array, null given...").
@amaria Thank you, patch realy did the work.

mparker17’s picture

Version: 7.x-1.0 » 7.x-1.x-dev
Priority: Normal » Major

I was able to reproduce this on a clean install using seo_ui-7.x-1.x head.

Marking as major because this bug prevents nodes from being saved (rendering system unusable) but only when Open Graph meta tags is enabled.

Steps to reproduce:

  1. Installed drupal-7.12, minimal install profile.
  2. Installed ctools-7.x-1.0, metatag-7.x-1.0-alpha5, redirect-7.x-1.0-beta4, pathauto-7.x-1.0.
  3. Installed seo_ui-7.x-1.x head (commit 81fab8fc5f0f6bb1b227814aee879de24fb6c570).
  4. From Administration -> Modules, enabled:
    • Core -> Path
    • Meta tags -> Meta tags
    • Meta tags -> Open Graph meta tags
    • Other -> Pathauto
    • Other -> Redirect
    • Other -> Unified SEO UI
  5. From Administration -> Structure -> Content types created a page content type.
  6. From Add content -> Page, created a node. Put test text in for Title and Body, but didn't change any other options. Clicked Save.
  7. Recieved error.

I applied the patch in #4, repeated step 6 and was able to save the node successfully.

If the patch in #4 could be changed to conform to Drupal coding standards (see the section on operators), this issue could be marked RTBC.

playfulwolf’s picture

anyone to apply the patch?

p.s. getting the same error

PatchRanger’s picture

Patch re-rolled to make it to conform Drupal coding standarts.

PatchRanger’s picture

Status: Needs review » Reviewed & tested by the community

Marking as 'r&tbc' due to #6.

jessebeach’s picture

Status: Reviewed & tested by the community » Closed (fixed)

Thank you all for the patch and the excellent steps-to-reproduce. Sorry for the delay addressing this.

Fixed in 7.x-1.x. I'll roll a new release after I fix one more issue that throwing messages.