diff options
author | zottel <github@zottel.net> | 2012-05-07 09:11:45 +0200 |
---|---|---|
committer | zottel <github@zottel.net> | 2012-05-07 09:11:45 +0200 |
commit | a2ea560bf397902ce5608daabf101d0bcf813f13 (patch) | |
tree | 0f4020d6b86c65cc317739b8e562ea50801ec277 /include/text.php | |
parent | 3cd428152d8727b838565c462f91accd35204ce1 (diff) | |
parent | c7f3e626d0bb141be86a8af6ffbe40768bc23069 (diff) | |
download | volse-hubzilla-a2ea560bf397902ce5608daabf101d0bcf813f13.tar.gz volse-hubzilla-a2ea560bf397902ce5608daabf101d0bcf813f13.tar.bz2 volse-hubzilla-a2ea560bf397902ce5608daabf101d0bcf813f13.zip |
Merge remote branch 'upstream/master'
Diffstat (limited to 'include/text.php')
-rw-r--r-- | include/text.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/include/text.php b/include/text.php index 4ae5d1333..1b5b0afd4 100644 --- a/include/text.php +++ b/include/text.php @@ -930,7 +930,8 @@ function prepare_body($item,$attach = false) { foreach($matches as $mtch) { if(strlen($x)) $x .= ','; - $x .= xmlify(file_tag_decode($mtch[1])) . ' <a href="' . $a->get_baseurl() . '/filerm/' . $item['id'] . '?f=&cat=' . xmlify(file_tag_decode($mtch[1])) . '" title="' . t('remove') . '" >' . t('[remove]') . '</a>'; + $x .= xmlify(file_tag_decode($mtch[1])) + . ((local_user() == $item['uid']) ? ' <a href="' . $a->get_baseurl() . '/filerm/' . $item['id'] . '?f=&cat=' . xmlify(file_tag_decode($mtch[1])) . '" title="' . t('remove') . '" >' . t('[remove]') . '</a>' : ''); } if(strlen($x)) $s .= '<div class="categorytags"><span>' . t('Categories:') . ' </span>' . $x . '</div>'; @@ -1490,7 +1491,7 @@ function file_tag_unsave_file($uid,$item,$file,$cat = false) { intval($uid) ); - $r = q("select file from item where uid = %d " . file_tag_file_query('item',$file,(($cat) ? 'category' : 'file')), + $r = q("select file from item where uid = %d and deleted = 0 " . file_tag_file_query('item',$file,(($cat) ? 'category' : 'file')), intval($uid) ); |