Bug 33940: (QA follow-up) Remove obsolete length of 20

Currently 32. Could be 43 tomorrow :)

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Marcel de Rooy 2023-07-21 09:44:18 +00:00 committed by Tomas Cohen Arazi
parent 3d2267b643
commit dc4bf60031
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F

View file

@ -85,7 +85,7 @@ sub get_valid_length {
my ($class) = @_; my ($class) = @_;
my $borrower = Koha::Database->new->schema->resultset('Borrower'); my $borrower = Koha::Database->new->schema->resultset('Borrower');
my $field_size = $borrower->result_source->column_info('cardnumber')->{size}; my $field_size = $borrower->result_source->column_info('cardnumber')->{size};
my ( $min, $max ) = ( 0, $field_size ); # borrowers.cardnumber is a nullable varchar(20) my ( $min, $max ) = ( 0, $field_size );
$min = 1 if C4::Context->preference('BorrowerMandatoryField') =~ /cardnumber/; $min = 1 if C4::Context->preference('BorrowerMandatoryField') =~ /cardnumber/;
if ( my $cardnumber_length = C4::Context->preference('CardnumberLength') ) { if ( my $cardnumber_length = C4::Context->preference('CardnumberLength') ) {