Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Similar to #2289603: "Cannot define PRIMARY KEY constraint on nullable column in table file_metadata", I was updating from Media v1 to v2-dev on a site running against SQL Server, when the following errors arose while running the database updates:
Notice: Undefined property: stdClass::$streams in media_update_7208() (line 859 of media/media.install).
array_merge(): Argument #2 is not an array media.install:846 [warning]
array_merge(): Argument #2 is not an array media.install:846 [warning]
array_merge(): Argument #2 is not an array media.install:846 [warning]
Performed update: media_update_7208 [ok]
Comment | File | Size | Author |
---|---|---|---|
#1 | fix-array-merge-warning-2289605-1.patch | 615 bytes | antondavidsen |
Comments
Comment #1
antondavidsen CreditAttribution: antondavidsen commentedIf the $new_type->streams is empty or not an array, array_merge() will throw an error. A patch against revision fe09f096029e7c495f0023afd7192aa081f0e080 is supplied.
Comment #2
Devin Carlson CreditAttribution: Devin Carlson commentedComment #3
jwilson3In addition to the "Argument #2 is not an array media.install" error, I'm also getting another error message related to this issue:
I'm currently testing patch in #1 and will report back...
Comment #4
Chris Matthews CreditAttribution: Chris Matthews as a volunteer commentedThe 4 year old patch in #1 to media.install does not apply to the latest media 7.x-2.x-dev and per joseph.olstad's closing as outdated. However, if you still need this and want it reviewed, feel free to submit a re-rolled patch and he will consider re-opening.