Bugzilla – Attachment 86991 Details for
Bug 22577
Cronjobs (and other scripts) should be attributed to a 'real' user
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 22577: Prevent deletion of system users
Bug-22577-Prevent-deletion-of-system-users.patch (text/plain), 757 bytes, created by
Martin Renvoize (ashimema)
on 2019-03-25 19:05:39 UTC
(
hide
)
Description:
Bug 22577: Prevent deletion of system users
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2019-03-25 19:05:39 UTC
Size:
757 bytes
patch
obsolete
>From 993508e951544c2c74e8576e9d551f52db6fe37d Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Mon, 25 Mar 2019 19:04:08 +0000 >Subject: [PATCH] Bug 22577: Prevent deletion of system users > >--- > Koha/Patron.pm | 5 +++++ > 1 file changed, 5 insertions(+) > >diff --git a/Koha/Patron.pm b/Koha/Patron.pm >index eeaf0e4dc2..33056d7483 100644 >--- a/Koha/Patron.pm >+++ b/Koha/Patron.pm >@@ -317,6 +317,11 @@ other lists are kept. > sub delete { > my ($self) = @_; > >+ unless ( $self->borrowernumber > 0 ) { >+ Koha::Exceptions::CannotDeleteDefault->throw( >+ { message => "Cannot delete system user" } ); >+ } >+ > my $deleted; > $self->_result->result_source->schema->txn_do( > sub { >-- >2.20.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 22577
:
86991
|
86992
|
86993
|
87007
|
87008
|
87013
|
87014
|
87015
|
87017
|
87028
|
87029
|
87030
|
87031
|
87032
|
87053
|
87054
|
87055
|
87056
|
87057
|
87058
|
87059
|
87060