Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
They look pretty simiilar so i'm wondering what's the difference.
At some places while scanning this code i thougth "ugh this probably causes a bug."
Comments
Comment #1
threewestwinds CreditAttribution: threewestwinds commentedAfter digging through the code (with the help of grep), I believe that the existence of $view->exposed_data is a bug. $view->exposed_input is used in fewer places, but it does have an intelligent getter and setter. They sometimes hold the same value - when they diverge, it's only because ->exposed_data was udated, while ->exposed_input was not. But we already have raw_exposed_data for holding the original values from the form, if they're needed for something.
Some quick testing shows that replacing all references to exposed_data to exposed_input (and preferring to use $view->set_exposed_input) has no visible side effects. I'll create a patch if we decide to go in that direction.
I'd rather have set_exposed_input set $view->exposed_input, since we can't change a public function name randomly.
Comment #2
merlinofchaos CreditAttribution: merlinofchaos commentedI have no memory of why these are different, so it may have just been a side effect of being sleep deprived when I wrote the exposed filter code.
Comment #3
MustangGB CreditAttribution: MustangGB commentedMaybe don't worry about it for D7, and fix it in core if still applicable.