Project

General

Profile

Actions

Bug #88900

closed

Incorrect PHPDoc of "stdWrap_encodeForJavaScriptValue"

Added by Felix Heller over 5 years ago. Updated almost 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Documentation
Target version:
-
Start date:
2019-08-02
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
10
PHP Version:
Tags:
Complexity:
no-brainer
Is Regression:
No
Sprint Focus:

Description

In https://github.com/TYPO3/TYPO3.CMS/blob/e58f47f77855f8082ea19e4c0dd7aad1f02e08cb/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php#L2455, the PHPDoc of the method stdWrap_encodeForJavaScriptValue is:

encodeForJavaScriptValue
Escapes content to be used inside JavaScript strings. No quotes are added around the value as this can easily be done in TypoScript

Although in https://github.com/TYPO3/TYPO3.CMS/blob/e58f47f77855f8082ea19e4c0dd7aad1f02e08cb/typo3/sysext/core/Classes/Utility/GeneralUtility.php#L3744, the return value of quoteJSvalue is described as:

@return string the encoded value already quoted (with single quotes)

The PHPDoc of stdWrap_encodeForJavaScriptValue is incorrect, the returned value is already quoted.

Actions #1

Updated by Gerrit Code Review over 5 years ago

  • Status changed from New to Under Review

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

Actions #2

Updated by Gerrit Code Review over 5 years ago

Patch set 1 for branch 9.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/+/61362

Actions #3

Updated by Felix Heller over 5 years ago

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

Updated by Benni Mack almost 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF