@@ -, +, @@ --> without this patch you will se error message: Can't call method "can_edit_item" on an undefined value at /home/vagrant/kohaclone/C4/Items.pm line 1748 --> with this patch everything works smoothly --- C4/Items.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/C4/Items.pm +++ a/C4/Items.pm @@ -1730,7 +1730,7 @@ sub ItemSafeToDelete { if ($item->checkout) { $status = "book_on_loan"; } - elsif ( defined C4::Context->userenv + elsif ( defined C4::Context->userenv and defined C4::Context->userenv->{number} and !Koha::Patrons->find( C4::Context->userenv->{number} )->can_edit_item( $item ) ) { $status = "not_same_branch"; --