From 956dab69b480fbc91a1735b66c0cf46a98d334ef Mon Sep 17 00:00:00 2001 From: redmatrix Date: Thu, 8 Sep 2016 22:20:45 -0700 Subject: illegal offset errors in include/conversation:status_editor() when no permissions array is passed --- include/conversation.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/conversation.php b/include/conversation.php index f06016966..e515fb26a 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -1213,6 +1213,10 @@ function status_editor($a, $x, $popup = false) { if(! $cipher) $cipher = 'aes256'; + // avoid illegal offset errors + if(! array_key_exists('permissions',$x)) + $x['permissions'] = [ 'allow_cid' => '', 'allow_gid' => '', 'deny_cid' => '', 'deny_gid' => '' ]; + $jotplugins = ''; call_hooks('jot_tool', $jotplugins); -- cgit v1.2.3