{"action":"created","issue":{"url":"https://api.github.com/repos/ten24/slatwall/issues/6518","repository_url":"https://api.github.com/repos/ten24/slatwall","labels_url":"https://api.github.com/repos/ten24/slatwall/issues/6518/labels{/name}","comments_url":"https://api.github.com/repos/ten24/slatwall/issues/6518/comments","events_url":"https://api.github.com/repos/ten24/slatwall/issues/6518/events","html_url":"https://github.com/ten24/slatwall/pull/6518","id":336438432,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk3ODkyMDE2","number":6518,"title":"Fixing weird issue in buildFormCollections with Lucee","user":{"login":"tdhatcher","id":360359,"node_id":"MDQ6VXNlcjM2MDM1OQ==","avatar_url":"https://avatars1.githubusercontent.com/u/360359?v=4","gravatar_id":"","url":"https://api.github.com/users/tdhatcher","html_url":"https://github.com/tdhatcher","followers_url":"https://api.github.com/users/tdhatcher/followers","following_url":"https://api.github.com/users/tdhatcher/following{/other_user}","gists_url":"https://api.github.com/users/tdhatcher/gists{/gist_id}","starred_url":"https://api.github.com/users/tdhatcher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tdhatcher/subscriptions","organizations_url":"https://api.github.com/users/tdhatcher/orgs","repos_url":"https://api.github.com/users/tdhatcher/repos","events_url":"https://api.github.com/users/tdhatcher/events{/privacy}","received_events_url":"https://api.github.com/users/tdhatcher/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-06-28T01:07:51Z","updated_at":"2018-07-26T17:37:48Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/ten24/slatwall/pulls/6518","html_url":"https://github.com/ten24/slatwall/pull/6518","diff_url":"https://github.com/ten24/slatwall/pull/6518.diff","patch_url":"https://github.com/ten24/slatwall/pull/6518.patch"},"body":"Fixing weird issue in buildFormCollections with Lucee auto-creating various form scope variables for keys with array syntax. It will cause buildFormCollections logic to overwrite and change key names back to array syntax causing populate to not work properly. Unintended behavior depends on the arbitrary order the keys arrange themselves in the form scope.\r\n\r\nCompare the difference between CF and Lucee with the same inputs. I was submitting several form fields\r\n```\r\n<input type=\"hidden\" name=\"materialFileGroups[1].materialFileGroupID\" value=\"\" />\r\n<input type=\"hidden\" name=\"materialFileGroups[1].materialFiles[1].materialFileID\" value=\"\" />\r\n<input id=\"file-upload\" type=\"file\" name=\"materialFileGroups[1].materialFiles[1].materialFileUpload\" />\r\n```\r\n\r\n[CF11 Form Scope.html.pdf](https://github.com/ten24/slatwall/files/2143366/CF11.Form.Scope.html.pdf)\r\n\r\n[Lucee5 Form Scope.html.pdf](https://github.com/ten24/slatwall/files/2143367/Lucee5.Form.Scope.html.pdf)\r\n\r\nThis shows the structure that buildFormCollections creates as it goes over the form scope. One depicts how the variables get overwritten or added to the wrong places. Other shows after the fix.\r\n\r\n[Issue - Lucee Form Scope Example.html.pdf](https://github.com/ten24/slatwall/files/2143368/Issue.-.Lucee.Form.Scope.Example.html.pdf)\r\n\r\n[Fixed - Lucee Form Scope Example.html.pdf](https://github.com/ten24/slatwall/files/2143369/Fixed.-.Lucee.Form.Scope.Example.html.pdf)\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/ten24/slatwall/issues/comments/408176093","html_url":"https://github.com/ten24/slatwall/pull/6518#issuecomment-408176093","issue_url":"https://api.github.com/repos/ten24/slatwall/issues/6518","id":408176093,"node_id":"MDEyOklzc3VlQ29tbWVudDQwODE3NjA5Mw==","user":{"login":"tdhatcher","id":360359,"node_id":"MDQ6VXNlcjM2MDM1OQ==","avatar_url":"https://avatars1.githubusercontent.com/u/360359?v=4","gravatar_id":"","url":"https://api.github.com/users/tdhatcher","html_url":"https://github.com/tdhatcher","followers_url":"https://api.github.com/users/tdhatcher/followers","following_url":"https://api.github.com/users/tdhatcher/following{/other_user}","gists_url":"https://api.github.com/users/tdhatcher/gists{/gist_id}","starred_url":"https://api.github.com/users/tdhatcher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tdhatcher/subscriptions","organizations_url":"https://api.github.com/users/tdhatcher/orgs","repos_url":"https://api.github.com/users/tdhatcher/repos","events_url":"https://api.github.com/users/tdhatcher/events{/privacy}","received_events_url":"https://api.github.com/users/tdhatcher/received_events","type":"User","site_admin":false},"created_at":"2018-07-26T17:37:48Z","updated_at":"2018-07-26T17:37:48Z","author_association":"MEMBER","body":"@sumitverma @rmarchandTen24 \r\nIt looks like at the present moment the Lucee specific handling is needed to get around the undesired behavior.\r\n\r\nhttps://dev.lucee.org/t/bug-issue-with-form-scope-array-bracket-notation-setting-to-disable/4088/4"}}
{"actor":{"display_login":"tdhatcher"}}