File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
src/Magento/FunctionalTestingFramework/Util Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -1644,13 +1644,13 @@ private function processPressKey($input)
16441644 $ arrayResult = [];
16451645 $ count = 0 ;
16461646
1647- // matches arrays
1647+ // matches all arrays and replaces them with placeholder to prevent later param manipulation
16481648 preg_match_all ('/[\[][^\]]*?[\]]/ ' , $ input , $ paramInput );
16491649 if (!empty ($ paramInput )) {
16501650 foreach ($ paramInput [0 ] as $ param ) {
1651- $ arrayResult [static ::PRESSKEY_ARRAY_ANCHOR_KEY . $ count ] =
1651+ $ arrayResult [self ::PRESSKEY_ARRAY_ANCHOR_KEY . $ count ] =
16521652 '[ ' . trim ($ this ->addUniquenessToParamArray ($ param )) . '] ' ;
1653- $ input = str_replace ($ param , static ::PRESSKEY_ARRAY_ANCHOR_KEY . $ count , $ input );
1653+ $ input = str_replace ($ param , self ::PRESSKEY_ARRAY_ANCHOR_KEY . $ count , $ input );
16541654 $ count ++;
16551655 }
16561656 }
@@ -1681,6 +1681,7 @@ private function processPressKey($input)
16811681 }
16821682
16831683 $ result = implode (', ' , $ result );
1684+ // reinsert arrays into result
16841685 if (!empty ($ arrayResult )) {
16851686 foreach ($ arrayResult as $ key => $ value ) {
16861687 $ result = str_replace ($ key , $ value , $ result );
You can’t perform that action at this time.
0 commit comments