Bug 22439

Summary: Duplicated code in PrepHostMarcField and prepare_host_field
Product: Koha Reporter: paxed <pasi.kallinen>
Component: CatalogingAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: m.de.rooy
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:

Description paxed 2019-03-01 09:06:13 UTC
The C4/Biblio.pm subroutines PrepHostMarcField and prepare_host_field both do the same thing, so should be merged.
Comment 1 paxed 2019-03-04 08:17:28 UTC
In addition:

1) prepare_host_field: if ( $field = $host->field('100') || $host->field('110') || $host->field('11') ) - the '11' should be '111'

2) prepare_host_field has a 240 -> 773b, which should be 250a -> 773b, as it is in PrepHostMarcField

3) There's a difference in how the 773a is set: prepare_host_field uses 100ab | 110ab | 11ab, but PrepHostMarcField uses 100a | 110a | 111a