Review main Merged

81178[BUGFIX] Return empty string in case the folder does not exist

Jochen Roth CR +2 V +2 Easy +4 −0 updated 09/22/23, 13:11

Commit message

Currently, when linking to a non-existing folder in and
the user clicks on save an error is thrown.

This has been fixed by returning early with a empty string
in case the folder object is null.

Review

  • Code review CR +2 Done
    • Stefan Bürk +2
    • Georg Ringer +1
    • Oliver Klee +1
  • Verified V +2 Done
    • Stefan Bürk +2
    • Georg Ringer +1
    • core-ci +1 CI

Issues 1

Files 1

Review log 1214

  1. Jochen Roth uploaded patch set 1 09/22/23, 11:13

  2. Oliver Klee voted on patch set 1 CR +1 09/22/23, 11:17

  3. core-ci voted on patch set 1 V +1 09/22/23, 11:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/47084

  4. Georg Ringer commented on patch set 1 CR -1 09/22/23, 11:21

    empty string is return, not null

    FolderLinkHandler.php:49

    should we use ($parameters['folder'] ?? null) === null)?
  5. Oliver Klee commented on patch set 1 09/22/23, 11:36

    FolderLinkHandler.php:49 Reply

    The short version of this would be: ```php if (isset($parameters['folder'] )) { ```
  6. Jochen Roth uploaded patch set 2 CR +1 V +1 09/22/23, 12:02

  7. Jochen Roth commented on patch set 2 09/22/23, 12:05

    Reply

    Done

    FolderLinkHandler.php:49 Reply

    Done
  8. Oliver Klee voted on patch set 2 CR +1 09/22/23, 12:06

  9. core-ci voted on patch set 2 V +1 09/22/23, 12:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/47085

  10. Georg Ringer voted on patch set 2 V +1 CR +1 09/22/23, 12:26

  11. Stefan Bürk voted on patch set 2 V +2 CR +2 09/22/23, 13:00

  12. Oli Bartsch commented on patch set 2 09/22/23, 13:08

    instanceof check would be more explicit. $parameters['folder'] could still be set but not a Folder object.
  13. Stefan Bürk merged patch set 3 09/22/23, 13:08

  14. Stefan Bürk commented on patch set 3 09/22/23, 13:11

    Reply

    Too late. Will create a follow up shortly.