diff options
author | Andrew Manning <andrewmanning@grid.reticu.li> | 2017-08-24 18:57:52 +0000 |
---|---|---|
committer | Andrew Manning <andrewmanning@grid.reticu.li> | 2017-08-24 18:57:52 +0000 |
commit | 90ec3340e44a3d3c69779f0db33ee49e864f326d (patch) | |
tree | 2b0bc859c3a7d31adcd1c9777d9868b9dbecdeda /Zotlabs/Module/Display.php | |
parent | cf2609530fcffdc7f5477336232b7cfde8b6403f (diff) | |
parent | cdccf601320ec7e59f5d96438edac34d5ea30085 (diff) | |
download | volse-hubzilla-90ec3340e44a3d3c69779f0db33ee49e864f326d.tar.gz volse-hubzilla-90ec3340e44a3d3c69779f0db33ee49e864f326d.tar.bz2 volse-hubzilla-90ec3340e44a3d3c69779f0db33ee49e864f326d.zip |
Merge remote-tracking branch 'upstream/dev' into doco
Diffstat (limited to 'Zotlabs/Module/Display.php')
-rw-r--r-- | Zotlabs/Module/Display.php | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/Zotlabs/Module/Display.php b/Zotlabs/Module/Display.php index d82ff2a55..b698513ba 100644 --- a/Zotlabs/Module/Display.php +++ b/Zotlabs/Module/Display.php @@ -39,7 +39,7 @@ class Display extends \Zotlabs\Web\Controller { $observer_is_owner = false; $updateable = false; - + if(local_channel() && (! $update)) { $channel = \App::get_channel(); @@ -174,8 +174,13 @@ class Display extends \Zotlabs\Web\Controller { '$verb' => '', '$mid' => $item_hash )); - - + + head_add_link([ + 'rel' => 'alternate', + 'type' => 'application/json+oembed', + 'href' => z_root() . '/oep?f=&url=' . urlencode(z_root() . '/' . \App::$query_string), + 'title' => 'oembed' + ]); } $observer_hash = get_observer_hash(); @@ -214,17 +219,17 @@ class Display extends \Zotlabs\Web\Controller { if($r === null) { // in case somebody turned off public access to sys channel content using permissions - // make that content unsearchable by ensuring the owner_xchan can't match + // make that content unsearchable by ensuring the owner uid can't match if(! perm_is_allowed($sysid,$observer_hash,'view_stream')) $sysid = 0; - + $r = q("SELECT item.id as item_id from item WHERE mid = '%s' AND (((( item.allow_cid = '' AND item.allow_gid = '' AND item.deny_cid = '' AND item.deny_gid = '' AND item_private = 0 ) - and owner_xchan in ( " . stream_perms_xchans(($observer_hash) ? (PERMS_NETWORK|PERMS_PUBLIC) : PERMS_PUBLIC) . " )) + and uid in ( " . stream_perms_api_uids(($observer_hash) ? (PERMS_NETWORK|PERMS_PUBLIC) : PERMS_PUBLIC) . " )) OR uid = %d ) $sql_extra ) $item_normal @@ -232,7 +237,7 @@ class Display extends \Zotlabs\Web\Controller { dbesc($target_item['parent_mid']), intval($sysid) ); - + } } } |