Bug #46935
closedConditions checking for "empty" values (not set or zero) not possible
0%
Description
Works: [globalVar = GP:type = 10]
Does not work: [globalVar = GP:type = 0]
Imho we might want to behave like empty() does, so "GP:type = 0" matches in case type is zero or even if it is not set. Since checking for a zero-value was not possible until now I think this would be a backward-compatible change.
Updated by Mathias Schreiber almost 10 years ago
- Target version set to 7.2 (Frontend)
- Is Regression set to No
Updated by Benni Mack over 9 years ago
- Target version changed from 7.2 (Frontend) to 7.4 (Backend)
Updated by Susanne Moog over 9 years ago
- Target version changed from 7.4 (Backend) to 7.5
Updated by Benni Mack about 9 years ago
- Status changed from New to Needs Feedback
- Target version deleted (
7.5)
Care to create a patch fore that?
Updated by Gerrit Code Review about 9 years ago
- Status changed from Needs Feedback 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 http://review.typo3.org/43536
Updated by Gerrit Code Review about 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/43536
Updated by Gerrit Code Review over 8 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/43536
Updated by Gerrit Code Review over 8 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/43536
Updated by Gerrit Code Review over 8 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/43536
Updated by Oliver Hader over 8 years ago
Current evaluation (without the patch):¶
Condition | GET/POST | Result |
globalVar = GP:test = | &test= | true |
globalVar = GP:test = 0 | &test= | false |
globalVar = GP:test = | &test=0 | false |
globalVar = GP:test = 0 | &test=0 | true |
Future evaluation (with the patch):¶
Condition | GET/POST | Result |
globalVar = GP:test = | &test= | true |
globalVar = GP:test = 0 | &test= | true |
globalVar = GP:test = | &test=0 | true |
globalVar = GP:test = 0 | &test=0 | true |
Conclusion¶
With the patch, the checks are more weak concerning zero and empty values. There's no difference anymore.
However, to achieve this, conditions can be joined already:
[globalVar = GP:test = 0, GP:test =]
Updated by Christian Kuhn over 8 years ago
- Status changed from Under Review to Rejected
this is closed as "not a bug" for now.