Fix for storing posts of private forums
This commit is contained in:
parent
3488b937ea
commit
bb0cf93374
|
@ -2576,11 +2576,12 @@ class Item extends BaseObject
|
||||||
|
|
||||||
$private = ($user['allow_cid'] || $user['allow_gid'] || $user['deny_cid'] || $user['deny_gid']) ? 1 : 0;
|
$private = ($user['allow_cid'] || $user['allow_gid'] || $user['deny_cid'] || $user['deny_gid']) ? 1 : 0;
|
||||||
|
|
||||||
|
$psid = PermissionSet::fetchIDForPost($user);
|
||||||
|
|
||||||
$forum_mode = ($prvgroup ? 2 : 1);
|
$forum_mode = ($prvgroup ? 2 : 1);
|
||||||
|
|
||||||
$fields = ['wall' => true, 'origin' => true, 'forum_mode' => $forum_mode, 'contact-id' => $self['id'],
|
$fields = ['wall' => true, 'origin' => true, 'forum_mode' => $forum_mode, 'contact-id' => $self['id'],
|
||||||
'owner-id' => $owner_id, 'owner-link' => $self['url'], 'private' => $private, 'allow_cid' => $user['allow_cid'],
|
'owner-id' => $owner_id, 'private' => $private, 'psid' => $psid];
|
||||||
'allow_gid' => $user['allow_gid'], 'deny_cid' => $user['deny_cid'], 'deny_gid' => $user['deny_gid']];
|
|
||||||
self::update($fields, ['id' => $item_id]);
|
self::update($fields, ['id' => $item_id]);
|
||||||
|
|
||||||
self::updateThread($item_id);
|
self::updateThread($item_id);
|
||||||
|
|
Loading…
Reference in a new issue