Bug 25526: Equality matching is case sensative
[koha.git] / members / paycollect.pl
index 43c52c7..c258560 100755 (executable)
@@ -43,7 +43,7 @@ my $writeoff_individual = $input->param('writeoff_individual');
 my $change_given        = $input->param('change_given');
 my $type                = scalar $input->param('type') || 'PAYMENT';
 
-my $updatecharges_permissions = ($writeoff_individual || $type eq 'writeoff') ? 'writeoff' : 'remaining_permissions';
+my $updatecharges_permissions = ($writeoff_individual || $type eq 'WRITEOFF') ? 'writeoff' : 'remaining_permissions';
 my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
     {   template_name   => 'members/paycollect.tt',
         query           => $input,
@@ -166,7 +166,7 @@ if ( $total_paid and $total_paid ne '0.00' ) {
             error_over => 1,
             total_due => $total_due
         );
-    } elsif ( $total_collected < $total_paid && !( $writeoff_individual || $type eq 'writeoff') ) {
+    } elsif ( $total_collected < $total_paid && !( $writeoff_individual || $type eq 'WRITEOFF' ) ) {
         $template->param(
             error_under => 1,
             total_paid => $total_paid