https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31925

--- Comment #53 from Martin Renvoize (ashimema) 
<[email protected]> ---
Phil/David/Pedro - I think comment 43/45's concern and comment 37's proposed
fix are actually the same thing, and haven't been reconciled into a patch yet,
so here's a first cut.
The scenario Pedro reproduced in comment 45 only bites because the *new*
authority gets coded for whatever thesaurus its creating heading happened to
carry, while the *matching* that later links a second, differently-coded
heading to that same authority ignores thesaurus entirely whenever
LinkerConsiderThesaurus is off. Before this bug, that mismatch couldn't happen
because AutoCreateAuthorities always created LCSH-coded records regardless of
the source heading - so the coding that later propagated onto linked bibs (via
the pre-existing "saving an authority updates its linked bib indicators"
behaviour David describes in comment 46) was always the coding most installs
already expect.
I've added a patch that gates the thesaurus-aware creation coding on
LinkerConsiderThesaurus, same as C4::Heading::_search and C4::Linker::Default
already do for matching (both call `$check_thesaurus =
C4::Context->preference('LinkerConsiderThesaurus')` / set thesaurus to
'notconsidered' when it's off). So:
- LinkerConsiderThesaurus off (default): AutoCreateAuthorities behaves exactly
as it does on main today - new authorities get the MARCAuthorityControlField008
default, full stop. Pedro's repro no longer triggers, because the FAST heading
no longer creates a FAST-coded authority.
- LinkerConsiderThesaurus on: this bug's fix applies as designed - new
authorities are coded for their source heading's real thesaurus, so
thesaurus-aware matching can actually find them again (the original bug 42694
problem).
This means the fix only benefits (and only changes behaviour for) sites that
already opted into thesaurus-aware linking, which are the only sites that were
ever going to see a benefit from it anyway - if LinkerConsiderThesaurus is off,
the linker never searches by thesaurus, so a thesaurus-correctly-coded
authority doesn't help it match any better than an LCSH-coded one did.
Added a regression test (case 7 in the existing subtest) covering the
LinkerConsiderThesaurus=off/FAST-heading scenario.
Does this close out the comment 43/45 concern for you both? Happy to adjust
further if there's a case this doesn't cover.

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to