Skip to content
Snippets Groups Projects
Commit ff98f405 authored by Sascha Egerer's avatar Sascha Egerer Committed by Benni Mack
Browse files

[BUGFIX] Revert behaviour of stdWrap ifEmpty

The stdWrap function ifEmpty must return true if a
PHP falsy value is given. That means e.g. an empty
string or a "0".

To make it more clear that stdWrap ifEmpty in fact
uses the logic of the PHP function "empty", this
function is now used.

First, the value is trimmed, which means a string
is returned, and then this value is passed to the
empty function.

As this works now properly, the getCurrentValue
method needed a check against empty array keys. The
stdWrap_current method now uses the getCurrentValue
method as they both do the exact same thing.

Resolves: #90908
Releases: main, 11.5
Change-Id: I3268fbaf68a2c56ae33ae499ad671e0a89fa7867
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/73081


Tested-by: default avatarcore-ci <typo3@b13.com>
Tested-by: default avatarBenni Mack <benni@typo3.org>
Reviewed-by: default avatarBenni Mack <benni@typo3.org>
parent 401068f6
Branches
Tags
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment