View | Details | Raw Unified | Return to bug 27145
Collapse All | Expand All

(-)a/members/deletemem.pl (-3 / +8 lines)
Lines 133-140 if ( $op eq 'delete_confirm' or $countissues > 0 or $debits or $is_guarantor ) { Link Here
133
    try {
133
    try {
134
        $patron->delete;
134
        $patron->delete;
135
        print $input->redirect("/cgi-bin/koha/members/members-home.pl");
135
        print $input->redirect("/cgi-bin/koha/members/members-home.pl");
136
    } catch {
136
    }
137
        print $input->redirect("/cgi-bin/koha/members/moremember.pl?borrowernumber=$member&error=CANT_DELETE_ANONYMOUS_PATRON");
137
    catch {
138
        if ( $_->isa('Koha::Exceptions::Patron::FailedDeleteAnonymousPatron') ) {
139
            print $input->redirect("/cgi-bin/koha/members/moremember.pl?borrowernumber=$member&error=CANT_DELETE_ANONYMOUS_PATRON");
140
        }
141
        else {
142
            $_->rethrow;
143
        }
138
    };
144
    };
139
    # TODO Tell the user everything went ok
145
    # TODO Tell the user everything went ok
140
    exit 0; # Exit without error
146
    exit 0; # Exit without error
141
- 

Return to bug 27145