From 979199c4426159035cca5245cee8e92fd7478fc5 Mon Sep 17 00:00:00 2001 From: Michael Date: Sun, 29 Mar 2020 11:16:40 +0000 Subject: [PATCH 1/2] Should fix the unknown "internal-psid" field --- src/Model/Item.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Model/Item.php b/src/Model/Item.php index d23a2e484..67fd2a357 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -177,7 +177,7 @@ class Item } $pinned = []; - while ($useritem = self::fetch($useritems)) { + while ($useritem = DBA::fetch($useritems)) { $pinned[] = $useritem['iid']; } DBA::close($useritems); From e17e385c4137116f7dd2c1e6d1676679a482e0a9 Mon Sep 17 00:00:00 2001 From: Michael Date: Sun, 29 Mar 2020 12:29:57 +0000 Subject: [PATCH 2/2] Fix: Queries with empty selections hadn't worked anymore --- src/Model/Item.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Model/Item.php b/src/Model/Item.php index 67fd2a357..7ac1ab300 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -846,7 +846,9 @@ class Item */ private static function constructSelectFields(array $fields, array $selected) { - $selected = array_merge($selected, ['internal-iid', 'internal-psid', 'internal-iaid', 'internal-network']); + if (!empty($selected)) { + $selected = array_merge($selected, ['internal-iid', 'internal-psid', 'internal-iaid', 'internal-network']); + } if (in_array('verb', $selected)) { $selected[] = 'internal-activity';