63692[BUGFIX] Wrap query parts in searchWhere into parentheses
Commit message
Review
-
Code review CR +2 Done
- Frank Nägler +2
- Stefan Froemken +1
-
Verified V +2 Done
- Frank Nägler +2
- Stefan Froemken +1
- TYPO3com +1 CI
Issues 1
Files 1
Review log 68
-
Georg Ringer uploaded patch set 1 03/12/20, 10:41
-
Georg Ringer commented on patch set 1 03/12/20, 10:42
This change is ready for review. -
TYPO3com voted on patch set 1 V +1 03/12/20, 10:56 Completed build in 15m 24s on Thu, 12 Mar, 10:56 AM Test Summary: 72194 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-1284
-
Stefan Froemken uploaded patch set 2 03/12/20, 22:48
-
Stefan Froemken commented on patch set 2 V +1 CR +1 03/12/20, 23:02
I have tested, xdebugged, reviewed and verified it within one of my own extensions. So hopefully +1 from myself should be OK.ContentObjectRenderer.php:6134UnresolvedThis will not work. Only, if you have two or more clauses, each of them will be wrapped into their own parentheses. If there is only ONE clause nothing will be wrapped. Before your patch: Two OR clauses results within orX() in "(a=1) OR (b=1)" -> goes into add(), until now we only have ONE clause, so nothing will be wrapped in add(). That's the mistake which should be solved. Result is still "(a=1) OR (b=1)". Your solution: Two OR clauses within orX() results in "(a=1) OR (b=1)". Now we have only ONE clause again which will be processed by andX(). As it is only ONE clause nothing will be wrapped. So still "(a=1) OR (b=1)". This will be processed by add(). As we still have only ONE clause nothing will be wrapped. Result is still "(a=1) OR (b=1)". Problem is still there. If you would build a query with this QueryBuilder now, everything will work, but here we try to build just a part of an incomplete Query which QueryBuilder does not know. That's why this will still break. So, we have to add the parentheses on our own. -
TYPO3com voted on patch set 2 V +1 03/12/20, 23:02 Completed build in 13m 44s on Thu, 12 Mar, 11:02 PM Test Summary: 72195 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-1305
-
Frank Nägler voted on patch set 2 V +2 CR +2 03/13/20, 19:37
-
Frank Nägler merged patch set 3 03/13/20, 19:37