Project

General

Profile

Actions

Bug #102328

closed

Regression in cObjGet

Added by Benjamin Franzke 6 months ago. Updated 6 months ago.

Status:
Resolved
Priority:
Should have
Assignee:
-
Category:
Code Cleanup
Start date:
2023-11-06
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
11
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Reported by Rafael Kähm in https://forge.typo3.org/issues/99503#note-13

Please reopen, because applied patch makes unnecessary BC at least on 11.5.
See:


    public function cObjGet($setup, $addKey = '')
    {
        return implode('', $this->cObjGetSeparated($setup, $addKey));
    }

    public function cObjGetSeparated(?array $setup, string $addKey = ''): array
    {
        if (!is_array($setup) || $setup === []) {
            return [];
        }

Proposal:

    public function cObjGet($setup, $addKey = '')
    {
        if (!is_array($setup)) {
            return '';
        }
        return implode('', $this->cObjGetSeparated($setup, $addKey));
    }

    public function cObjGetSeparated(?array $setup = [], string $addKey = ''): array
    {
        if (empty($setup)) {
            return [];
        }
    }

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #99503: Inline script concatenation requires scripts to have trailing ";"Resolved2023-01-10

Actions
Actions #1

Updated by Benjamin Franzke 6 months ago

  • Related to Bug #99503: Inline script concatenation requires scripts to have trailing ";" added
Actions #3

Updated by Gerrit Code Review 6 months ago

  • Status changed from New to Under Review

Patch set 2 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81698

Actions #4

Updated by Gerrit Code Review 6 months ago

Patch set 1 for branch 12.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81661

Actions #5

Updated by Gerrit Code Review 6 months ago

Patch set 1 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/81662

Actions #6

Updated by Anonymous 6 months ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions

Also available in: Atom PDF