Review main Merged

73034[BUGFIX] Prevent undefined key warning in IMG_RESOURCE cObj

Robert Kärner CR +2 V +2 Easy +1 −1 updated 01/17/22, 03:59

Commit message

Since the file property of an IMG_RESOURCE cObj might have
no direct value set, trying to access it must be protected
by a fallback, or an undefined array key warning is thrown.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
    • Chris Müller +1
    • Oliver Klee +1
    • Stefan Bürk +1
  • Verified V +2 Done
    • Christian Kuhn +2
    • Stefan Bürk +1
    • core-ci +1 CI

Issues 1

Files 1

Review log 89

  1. Robert Kärner uploaded patch set 1 01/16/22, 09:33

  2. Robert Kärner commented on patch set 1 01/16/22, 09:37

    ImageResourceContentObject.php:32

    I'm also fine with using `?? null` instead, but it requires the parameter signature of `getImgResource` to change to `string|File|FileReference|null` as well. Hence I went for `?? string` instead.
  3. core-ci voted on patch set 1 V +1 01/16/22, 09:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/22138

  4. Chris Müller voted on patch set 1 CR +1 01/16/22, 11:32

  5. Oliver Klee voted on patch set 1 CR +1 01/16/22, 13:54

  6. Christian Kuhn commented on patch set 1 V +1 CR +1 01/16/22, 18:38

    ImageResourceContentObject.php:32 Reply

    this is fine.
  7. Stefan Bürk voted on patch set 1 V +1 CR +1 01/16/22, 23:58

  8. Christian Kuhn voted on patch set 1 V +2 CR +2 01/17/22, 03:58

  9. Christian Kuhn merged patch set 2 01/17/22, 03:59