From 500633862e310db1e30ef4c700d8f864ca8c0a11 Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Mon, 16 Jul 2018 13:48:35 +0200 Subject: [PATCH] It is not possible to create private posts for groups. --- assets/js/components/posts/form.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/assets/js/components/posts/form.js b/assets/js/components/posts/form.js index 2a2c1350..ea1fc3f6 100644 --- a/assets/js/components/posts/form.js +++ b/assets/js/components/posts/form.js @@ -302,9 +302,11 @@ ComunicWeb.components.posts.form = { class: "post-visiblity-container" }); - //Private post - var privateLevel = ComunicWeb.components.posts.visibilityLevels.private; - var privateInput = this._add_visiblity_choice(visibility_choices_container, "private", privateLevel.name, privateLevel.icon); + if(kind != "group"){ + //Private post + var privateLevel = ComunicWeb.components.posts.visibilityLevels.private; + var privateInput = this._add_visiblity_choice(visibility_choices_container, "private", privateLevel.name, privateLevel.icon); + } //Friends-visible post var friendsLevel = ComunicWeb.components.posts.visibilityLevels.friends;