Problem/Motivation

PHP warning occurs when calling AssetUpdater::queueAssets() without the finalized-version option key in the $options array:
Warning: Undefined array key "finalized-version" in Drupal\acquia_dam\AssetUpdater::queueAssets() (line 62)

Steps to reproduce

  1. Call AssetUpdater::queueAssets() with options missing the finalized-version key:
    $updater->queueAssets(['batch-size' => 50]); // Missing 'finalized-version'
    Or invoke via Drush/CLI/UI where options array lacks this specific key.
  2. Observe the warning at line 62:
    $finalized_version = (bool) ($options['finalized-version'] ?? FALSE);

Proposed resolution

  • Replace direct array access with safe key checking like array_key_exists() or isset().

Issue fork acquia_dam-3565608

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

rajeshreeputra created an issue. See original summary.

rajeshreeputra’s picture

Status: Active » Needs review

Requesting review.

rajeshreeputra’s picture

Status: Needs review » Fixed

Merged!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

Status: Fixed » Closed (fixed)

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