MigrateItemJSON::clean() constructItemUrl count() on a variable that may not be an array. In PHP 7.2 this generates a exception with the following text:

Migration for TestMigrateMigration failed with source plugin exception: count(): Parameter must be an array or an object that implements Countable
File contrib/migrate/plugins/sources/json.inc, line 157

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

xlin created an issue. See original summary.

xlin’s picture

Please see attached patch.

xlin’s picture

brianfisher’s picture

Status: Active » Reviewed & tested by the community

+1

pifagor’s picture

  • pifagor committed 3877dad on 7.x-2.x authored by xlin
    Issue #3027630 by xlin, tbfisher, pifagor: PHP 7.2: count() on non-...
pifagor’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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

joseph.olstad’s picture