Closed (fixed)
Project:
Webform
Version:
7.x-4.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
1 Mar 2018 at 10:22 UTC
Updated:
6 Dec 2018 at 23:34 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
liam morlandThis may be a duplicate of #2842513: Undefined index: operator in _webform_conditional_expand().
Comment #3
Snehal Brahmbhatt commented@Liam Morland, Please find this patch to resolve the above-mentioned patch, I received it in the AJAX when installing the module.
Comment #4
liam morlandWhy is
empty()changed to!empty()?With this patch, $new[0] is not set if $parent_values[$rid]['source_type'] is not set, rather than getting $default_rule. Is that intentional?
Comment #5
Snehal Brahmbhatt commented@Liam Morland, Thanks for reviewing my patch, I updated it again. Kindly review it & let me know if any further change is required. Thanks!..
Comment #6
liam morlandCan you answer the second question in #4?
Comment #7
joelpittet@Liam Morland, good question, it's probably not intentional.
$new[0]is however set in the else block but not to the$default_rule.I can't really follow the logic myself so not sure which is correct, maybe you know?
Comment #8
liam morlandI don't know what it is supposed to be like. For fixing undefined index errors, I hesitate to make any changes in how it works unless I am sure it is actually a bug.
Comment #9
liam morlandDoes this solve it for you? This shouldn't have any effect on the functionality.
This may have been resolved in #2842513: Undefined index: operator in _webform_conditional_expand(). Have you reproduced the issue on 7.x-4.18?
Comment #10
joelpittetI've seen it recently (Nov 6th in 7.x-4.18), that looks like it would fix the notice without changing how it works, thanks @Liam Morland.
Comment #12
liam morlandThanks everyone!