From 645f9387fa2123dac3333bb82a29a8f290d39032 Mon Sep 17 00:00:00 2001 From: Jonny Tischbein Date: Fri, 26 Oct 2018 15:00:15 +0200 Subject: [PATCH] make return url optional --- include/items.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/include/items.php b/include/items.php index 6eb1345889..961a20b240 100644 --- a/include/items.php +++ b/include/items.php @@ -345,7 +345,7 @@ function drop_items(array $items) } } -function drop_item($id, $return) +function drop_item($id, $return = '') { $a = BaseObject::getApp(); @@ -410,8 +410,7 @@ function drop_item($id, $return) Item::deleteForUser(['id' => $item['id']], local_user()); $return_url = hex2bin($return); - notice("RETURN: " + $return_url); - if (empty($return_url) || strpos($return_url, 'display') ) { + if (empty($return_url) || strpos($return_url, 'display') !== false) { $a->internalRedirect('network'); //NOTREACHED } -- 2.39.5