Project

General

Profile

Actions

Bug #28234

closed

Chained stdWrap is broken for boolean stdWrap function types

Added by Jo Hasenau over 12 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Must have
Category:
TypoScript
Target version:
Start date:
2011-07-15
Due date:
% Done:

100%

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

Description

Since 4.5 we have stdWrap functions available to be chained with other stdWrap functions.
So we can do something like

10 = TEXT
10.value = 10*20
10.prioriCalc = 1
10.prioriCalc.if.isTrue.field = doCalculation

Unfortunately this doesn't work for boolean functions like prioriCalc, since they don't set the corresponding "isExecuted" key when their result was false in the first run.
This is why the function will be called twice, while having the value set to "Array" in the second run, which will always return something else than false.

Therefor we need an additional "else if" to check for this special case and set the key to avoid the second function call.

I can't push to GIT currently, so attached you find a patch that solves this problem.


Files

class.tslib_content.php.diff (1.33 KB) class.tslib_content.php.diff Jo Hasenau, 2011-07-15 14:32
Actions #1

Updated by Stefan Neufeind over 12 years ago

I'll take a look.

Actions #2

Updated by Mr. Hudson over 12 years ago

Patch set 1 of change If35c3bb3572265109207d3835135d9cc5d487a0a has been pushed to the review server.
It is available at http://review.typo3.org/3355

Actions #3

Updated by Mr. Hudson over 12 years ago

Patch set 2 of change If35c3bb3572265109207d3835135d9cc5d487a0a has been pushed to the review server.
It is available at http://review.typo3.org/3355

Actions #4

Updated by Mr. Hudson over 12 years ago

Patch set 1 of change I69855b88d5f2f782d99e78fe6dc83c3ac6373ff7 has been pushed to the review server.
It is available at http://review.typo3.org/3698

Actions #5

Updated by Xavier Perseguers over 12 years ago

  • Status changed from New to Resolved
  • Assignee changed from Steffen Kamper to Xavier Perseguers
  • % Done changed from 0 to 100

master: Change has been successfully cherry-picked as 7fd9bfc54e00d14d70e2d280799a30f4f47eb612.
TYPO3_4-5: Change has been successfully cherry-picked as aa3f554b31ca46a6cc66d036ed273fee8da42332.

Actions #6

Updated by Riccardo De Contardi over 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF