From 5f26f145b013cd501f30c875b06fc252b5f8c44b Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 8 Aug 2016 14:13:10 +0100 Subject: [PATCH] Bug 17080: borrowers.checkprevcheckout - use the default value defined in the DBIx::Class schema This line has been added by bug 16917 to define the default value of borrowers.checkprevcheckout. As this value is defined in the DBIx::Class schema, we should not have to handle it here. Test plan: Confirm that this patch does not reintroduced the bug fixed by bug 16917. --- C4/Members.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/C4/Members.pm b/C4/Members.pm index b868fd8..ea70e66 100644 --- a/C4/Members.pm +++ b/C4/Members.pm @@ -687,9 +687,10 @@ sub AddMember { $data{'sms_provider_id'} = undef if ( not $data{'sms_provider_id'} ); # get only the columns of Borrower + # FIXME Do we really need this check? my @columns = $schema->source('Borrower')->columns; my $new_member = { map { join(' ',@columns) =~ /$_/ ? ( $_ => $data{$_} ) : () } keys(%data) } ; - $new_member->{checkprevcheckout} ||= 'inherit'; + delete $new_member->{borrowernumber}; my $patron = Koha::Patron->new( $new_member )->store; -- 2.8.1