minor fixes

This commit is contained in:
nobody 2022-02-17 22:14:27 -08:00
parent 2a3ade5f89
commit 47206383b4
3 changed files with 4 additions and 2 deletions

View file

@ -290,7 +290,7 @@ class Libprofile
$xchan = q("SELECT * from xchan where xchan_hash = '%s'",
dbesc($profile['channel_hash'])
}
);
$is_group = ($xchan && intval($xchan[0]['xchan_type']) === XCHAN_TYPE_GROUP);
$can_dm = perm_is_allowed($profile['uid'], (is_array($observer)) ? $observer['xchan_hash'] : EMPTY_STR, 'post_mail') && $is_group ;

View file

@ -81,6 +81,8 @@ define ( 'TEMPLATE_BUILD_PATH', 'cache/smarty3' );
// The only ones of consequence in 2021 are DIRECTORY_MODE_NORMAL and DIRECTORY_MODE_STANDALONE.
define ( 'DIRECTORY_MODE_NORMAL', 0x0000); // A directory client
define ( 'DIRECTORY_MODE_PRIMARY', 0x0001); // There can only be *one* primary directory server in a directory_realm.
define ( 'DIRECTORY_MODE_SECONDARY', 0x0002); // All other mirror directory servers
define ( 'DIRECTORY_MODE_STANDALONE', 0x0100); // A detached (off the grid) hub with itself as directory server.
// Types of xchan records. These are a superset of ActivityStreams Actor types

View file

@ -35,7 +35,7 @@
{{/if}}
{{if $nav.channels}}
{{foreach $nav.channels as $chan}}
<a class="dropdown-item" href="manage/{{$chan.channel_id}}" title="{{$chan.channel_name}}" role="menuitem"><i class="fa fa-circle{{if $localuser == $chan.channel_id}} text-success{{else}} invisible{{/if}}"></i> {{$chan.channel_name}}</a>
<a class="dropdown-item" href="manage/{{$chan.channel_id}}" title="{{$chan.channel_name}}" role="menuitem"><i class="fa fa-circle{{if $localuser == $chan.channel_id}} text-success{{else}} invisible{{/if}}"></i> {{if $chan.channel_system}}<strong>{{$chan.channel_name}}</strong>{{else}}{{$chan.channel_name}}{{/if}}</a>
{{/foreach}}
{{/if}}
{{if $nav.profiles}}