Bug 16199

Summary: C4::Ris::charconv is one of the less useful subroutines ever written
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Architecture, internals, and plumbingAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: brendan, julian.maurice
Version: unspecified   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on: 16191    
Bug Blocks:    
Attachments: Bug 16199: Remove C4::Ris::charconv
Bug 16199: Remove C4::Ris::charconv
Bug 16199: Remove C4::Ris::charconv

Description Jonathan Druart 2016-04-05 06:49:41 UTC
I let you admire it:

sub charconv {
    if ($utf) {
       ## return unaltered if already utf-8
       return @_;
    }
    elsif (my $uniout eq "t") {
       ## convert to utf-8
       return marc8_to_utf8("@_");
    }
    else {
       ## return unaltered if no utf-8 requested
       return @_;
    }
}
Comment 1 Jonathan Druart 2016-04-05 06:55:22 UTC Comment hidden (obsolete)
Comment 2 Mark Tompsett 2016-04-05 13:11:26 UTC Comment hidden (obsolete)
Comment 3 Tomás Cohen Arazi 2016-04-05 14:34:59 UTC
Created attachment 49916 [details] [review]
Bug 16199: Remove C4::Ris::charconv

This subroutine always returns what has been sent in parameter.
It is unecessary and can be removed.

Test plan:
  prove t/Ris.t
should not be noisy

Export a catalogue record in Ris should generate the same file with and
without this patch

NOTE: With/Without were identical in my testing.
      t/Ris.t is nicely silenced.

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 4 Brendan Gallagher 2016-04-07 00:00:17 UTC
Pushed to Master - Should be in the May 2016 release.  Thanks!
Comment 5 Julian Maurice 2016-06-16 08:54:02 UTC
Patch pushed to 3.22.x, will be in 3.22.8