Closed (fixed)
Project:
Search API
Version:
8.x-1.x-dev
Component:
Plugins
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
18 Mar 2019 at 18:40 UTC
Updated:
20 Apr 2019 at 19:54 UTC
Jump to comment: Most recent, Most recent file

Comments
Comment #2
jonnyeom commentedComment #3
laravz commentedHi, thanks for your work! The patch applied to cleanly to the latest dev version of the module.
This solves the issue. The configuration is now being saved when the checkboxes are (un)checked.
This is not necessary in order to resolve the bug. I'm not really sure why you would want to unset 'strip'. Could you elaborate?
Comment #4
jonnyeom commented@LaravZ
My intention was to prevent duplicate data being saved in the configuration. Here is the entire snippet after the patch.
The data in the 'strip' form fields are being saved under a different name.
If I don't unset it, this is the config that would save for that field (Pasting my entire config as an example).
But in reality, keeping the duplicate data will not cause any errors anywhere.
Thoughts?
Comment #5
jonnyeom commentedRealized we don't need to
$form_state->getValue('ignorable')AnymoreComment #6
laravz commentedThe new patch also applied successfully, and the addition makes the code and resulting array cleaner. The issue also remains fixed.
Correct, I've verified this as well. I think it would be cleaner in the long run to slightly rework this so that it won't have to be resaved under a new name (and the unset won't be necessary). I do not, however, consider this to be a part of this commit, therefore I'll set this to RTBC.
Comment #7
drunken monkeyThanks a lot for reporting this! Seems we messed up back when fixing the form submission code in #3007933: IgnoreCharacters processor - “Strip by character property” not saving.
Your patch looks very good already, too, thanks for that, also! (And, of course, thanks @ LaravZ for reviewing!)
Anyways, we should also make sure the tests cover this in the future. Revised patch attached, please review! (No functional differences in non-test code.)
Comment #8
drunken monkeyIn fact, let’s add that to all the processor integration tests.
Comment #10
jonnyeom commentedLatest patch is working on our sites.
Thanks for the Test Updates!
Jonathan
Comment #11
laravz commentedI have no further remarks either. Patch applied cleanly and the 'all_fields' option is now taken into account with the unit tests. So this seems good to go, thanks!
Comment #13
drunken monkeyGreat to hear, thanks a lot for testing/reviewing!
Committed.
Thanks again, everyone!