Correcting C4::VirtualShelves::ShelfPossibleAction to handle the case where the staff user is the superlibrarian ($user == 0)
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
This commit is contained in:
parent
ed762eb989
commit
4d8963d9c9
1 changed files with 1 additions and 1 deletions
|
@ -476,7 +476,7 @@ sub ShelfPossibleAction {
|
|||
return 1 if ( $category >= 3); # open list
|
||||
return 1 if (($category >= 2) and
|
||||
defined($action) and $action eq 'view'); # public list, anybody can view
|
||||
return 1 if (($category >= 2) and defined($user) and $borrower->{authflags}->{superlibrarian}); # public list, superlibrarian can edit/delete
|
||||
return 1 if (($category >= 2) and defined($user) and ($borrower->{authflags}->{superlibrarian} || $user == 0)); # public list, superlibrarian can edit/delete
|
||||
return 1 if (defined($user) and $owner eq $user ); # user owns this list. Check last.
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue