Shown after update to latest dev. Just a placeholder, investigating now.

CommentFileSizeAuthor
#2 2537570-bad-css.patch662 bytesdavid_garcia
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

david_garcia’s picture

Who knows why, ['ajaxPageState']['css'] is an object:

  $setting['ajaxPageState']['css'] = (object) array_fill_keys(array_keys($css), 1);

While ['ajaxPageState']['js'] is a keyed array.

The error is from the brand new advagg_cleanup_settings_array:

  // Remove inline css from the ajaxPageState data.
  if (isset($data['ajaxPageState']['js'])) {
    foreach ($data['ajaxPageState']['css'] as $key => $value) {
      if (!advagg_remove_short_keys($key)) {
        unset($data['ajaxPageState']['css'][$key]);
      }
    }
  }

The previous logic does not seem right, it is mixing css and js, and not taking into account that css is an object instead of a keyed array.

Patch coming...

david_garcia’s picture

Priority: Normal » Major
Status: Active » Needs review
FileSize
662 bytes
david_garcia’s picture

Title: Fatal error: Cannot use object of type stdClass as array in D:\REPOSITORIOS_SABENTIS\drupal7\sites\all\modules\contrib\advagg\advagg.module on line 1909 » Fatal error: Cannot use object of type stdClass as array in advagg\advagg.module on line 1909

mikeytown2’s picture

Status: Needs review » Fixed

Thanks for the patch! It's been committed.

Status: Fixed » Needs work

The last submitted patch, 2: 2537570-bad-css.patch, failed testing.

mikeytown2’s picture

Status: Needs work » Fixed

Status: Fixed » Needs work

The last submitted patch, 2: 2537570-bad-css.patch, failed testing.

mikeytown2’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

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