From: Nick Clemens Date: Mon, 22 Apr 2019 15:05:51 +0000 (+0000) Subject: Bug 22748: Pass userid to haspermission X-Git-Url: http://git.equinoxoli.org/?p=koha-equinox.git;a=commitdiff_plain;h=f76f93ecf191231036c96b17fceccf819247959f Bug 22748: Pass userid to haspermission Signed-off-by: Agustin Moyano Signed-off-by: Katrin Fischer Signed-off-by: Nick Clemens --- diff --git a/cataloguing/addbiblio.pl b/cataloguing/addbiblio.pl index 8c60a11..246efa1 100755 --- a/cataloguing/addbiblio.pl +++ b/cataloguing/addbiblio.pl @@ -737,7 +737,7 @@ if ($frameworkcode eq 'FA'){ 'stickyduedate' => $fa_stickyduedate, 'duedatespec' => $fa_duedatespec, ); -} elsif ( $op ne "delete" && C4::Context->preference('EnableAdvancedCatalogingEditor') && C4::Auth::haspermission($loggedinuser,{'editcatalogue'=>'advanced_editor'}) && $input->cookie( 'catalogue_editor_' . $loggedinuser ) eq 'advanced' && !$breedingid ) { +} elsif ( $op ne "delete" && C4::Context->preference('EnableAdvancedCatalogingEditor') && C4::Auth::haspermission(C4::Context->userenv->{id},{'editcatalogue'=>'advanced_editor'}) && $input->cookie( 'catalogue_editor_' . $loggedinuser ) eq 'advanced' && !$breedingid ) { # Only use the advanced editor for non-fast-cataloging. # breedingid is not handled because those would only come off a Z39.50 # search initiated by the basic editor.