<commit_before>- set_title @group.name, ""
- if current_user && @group.parent.nil? && (not current_user.has_read_group_notice?)
  - message = "This is the Group page for \"#{@group.full_name}\". \n\n Here you can see the discussions for this group, "
  - message += "a description and a list of the group members. "
  - message += "You can start a new topic by clicking on the 'Start a discussion' button.\n\n"
  =render '/application/helper_info', message: message, path: dismiss_group_notice_for_user_path

%header
  -#= render '/application/loomio_process_flow'
  = render '/groups/title', group: @group
  = render '/application/button', :button_text => 'Start a discussion', :button_icon => 'topic',
    :args => {:href => "#new-discussion",  "data-toggle" => "modal", :class => 'btn btn-icon', :id => 'start-new-topic'}
.row
  %section.span8
    %ul.selector-list.bordered
      #all-discussions-loading
        %li.selector-item.loading Loading...
      #discussions-with-motions
        - @discussions_with_current_motion_not_voted_on.each do |discussion|
          %li.selector-item= render '/discussions/discussion_preview', discussion: discussion, this_group: @group
        - @discussions_with_current_motion_voted_on.each do |discussion|
          %li.selector-item= render '/discussions/discussion_preview', discussion: discussion, this_group: @group
        .discussion-with-motion-divider.hidden
      - if @group.discussions.count == 0
        %li.empty-list-message This group does not have any discussions yet.
      - else
        #group-discussions.hidden
          %div{ class: "group_#{@group.id}" }

  %section.span4
    =render 'request_membership', group: @group
    .sub-panel#group-description-panel
      %h3= "Group description"
      =render '/application/description', model: @group, model_name: "group"
    =render 'subgroups', subgroups: @subgroups, group: @group if display_subgroups_block?(@group)
    =render '/application/see_closed_motions'
    =render 'membership_requests', group: @group
    =render 'members', group: @group
  =render '/application/closed_motions', user: nil, group: @group

- if current_user
  =render '/discussions/new', discussion: @discussion, user_groups: nil
<commit_msg>Hide create discussion if insignificant priviledges.<commit_after>- set_title @group.name, ""
- if current_user && @group.parent.nil? && (not current_user.has_read_group_notice?)
  - message = "This is the Group page for \"#{@group.full_name}\". \n\n Here you can see the discussions for this group, "
  - message += "a description and a list of the group members. "
  - message += "You can start a new topic by clicking on the 'Start a discussion' button.\n\n"
  =render '/application/helper_info', message: message, path: dismiss_group_notice_for_user_path

%header
  -#= render '/application/loomio_process_flow'
  = render '/groups/title', group: @group
  - if can? :create, @discussion
    = render '/application/button', :button_text => 'Start a discussion', :button_icon => 'topic',
      :args => {:href => "#new-discussion",  "data-toggle" => "modal", :class => 'btn btn-icon', :id => 'start-new-topic'}
.row
  %section.span8
    %ul.selector-list.bordered
      #all-discussions-loading
        %li.selector-item.loading Loading...
      #discussions-with-motions
        - @discussions_with_current_motion_not_voted_on.each do |discussion|
          %li.selector-item= render '/discussions/discussion_preview', discussion: discussion, this_group: @group
        - @discussions_with_current_motion_voted_on.each do |discussion|
          %li.selector-item= render '/discussions/discussion_preview', discussion: discussion, this_group: @group
        .discussion-with-motion-divider.hidden
      - if @group.discussions.count == 0
        %li.empty-list-message This group does not have any discussions yet.
      - else
        #group-discussions.hidden
          %div{ class: "group_#{@group.id}" }

  %section.span4
    =render 'request_membership', group: @group
    .sub-panel#group-description-panel
      %h3= "Group description"
      =render '/application/description', model: @group, model_name: "group"
    =render 'subgroups', subgroups: @subgroups, group: @group if display_subgroups_block?(@group)
    =render '/application/see_closed_motions'
    =render 'membership_requests', group: @group
    =render 'members', group: @group
  =render '/application/closed_motions', user: nil, group: @group

- if can? :create, @discussion
  =render '/discussions/new', discussion: @discussion, user_groups: nil

{'fraction_non_alphanumeric': 0.1338599956111477, 'fraction_numerical': 0.0017555409260478386, 'mean_word_length': 3.792849631966351, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5693235', 'n_tokens_mistral': 1416, 'n_tokens_neox': 1364, 'n_words': 359}