aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Lib/ThreadItem.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2022-06-01 07:00:21 +0000
committerMario <mario@mariovavti.com>2022-06-01 07:00:21 +0000
commite63f0438415bb364f3085286ca2f199e83ab187b (patch)
treeb107429276ebfc92dc9b4f78e302a4967e5bf0a6 /Zotlabs/Lib/ThreadItem.php
parentc5f33baf27d80e2a7ad7307eacd3137609eeb089 (diff)
parent33dd0c83e377b8adf00559337d13784ec136cecb (diff)
downloadvolse-hubzilla-e63f0438415bb364f3085286ca2f199e83ab187b.tar.gz
volse-hubzilla-e63f0438415bb364f3085286ca2f199e83ab187b.tar.bz2
volse-hubzilla-e63f0438415bb364f3085286ca2f199e83ab187b.zip
Merge branch '7.4RC'7.4
Diffstat (limited to 'Zotlabs/Lib/ThreadItem.php')
-rw-r--r--Zotlabs/Lib/ThreadItem.php17
1 files changed, 2 insertions, 15 deletions
diff --git a/Zotlabs/Lib/ThreadItem.php b/Zotlabs/Lib/ThreadItem.php
index 8d20935a1..a02c1415e 100644
--- a/Zotlabs/Lib/ThreadItem.php
+++ b/Zotlabs/Lib/ThreadItem.php
@@ -162,24 +162,11 @@ class ThreadItem {
$mode = $conv->get_mode();
- switch($item['item_type']) {
- case ITEM_TYPE_CARD:
- $edlink = 'card_edit';
- break;
- case ITEM_TYPE_ARTICLE:
- $edlink = 'article_edit';
- break;
- default:
- $edlink = 'editpost';
- break;
- }
-
if(local_channel() && $observer['xchan_hash'] === $item['author_xchan'])
- $edpost = array(z_root() . '/' . $edlink . '/' . $item['id'], t('Edit'));
+ $edpost = array(z_root() . '/editpost/' . $item['id'], t('Edit'));
else
$edpost = false;
-
if($observer && $observer['xchan_hash']
&& ($observer['xchan_hash'] == $this->get_data_value('author_xchan')
|| $observer['xchan_hash'] == $this->get_data_value('owner_xchan')
@@ -297,7 +284,7 @@ class ThreadItem {
if($this->is_toplevel()) {
// FIXME check this permission
- if(($conv->get_profile_owner() == local_channel()) && (! array_key_exists('real_uid',$item))) {
+ if($conv->get_profile_owner() === local_channel() || intval($item['item_private']) === 0) {
$star = array(
'toggle' => t("Toggle Star Status"),