From 51e9f302b01968106f8d13e6f887a2f2f4f1aa13 Mon Sep 17 00:00:00 2001 From: zotlabs Date: Tue, 19 Feb 2019 13:36:53 -0800 Subject: hubzilla has uuid - use that instead of wildcard --- Zotlabs/Module/Id.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'Zotlabs/Module/Id.php') diff --git a/Zotlabs/Module/Id.php b/Zotlabs/Module/Id.php index cc43f0205..15abfa2a3 100644 --- a/Zotlabs/Module/Id.php +++ b/Zotlabs/Module/Id.php @@ -67,14 +67,14 @@ class Id extends Controller { $sql_extra = item_permissions_sql(0); - $r = q("select * from item where mid like '%s' $item_normal $sql_extra and uid = %d limit 1", - dbesc('%/' . $item_id), + $r = q("select * from item where uuid = '%s' $item_normal $sql_extra and uid = %d limit 1", + dbesc($item_id), intval($channel_id) ); if(! $r) { - $r = q("select * from item where mid like '%s' $item_normal and uid = %d limit 1", - dbesc('%/' . $item_id), + $r = q("select * from item where uuid = '%s' $item_normal and uid = %d limit 1", + dbesc($item_id), intval($channel_id) ); if($r) { -- cgit v1.2.3