diff --git a/app/models/group.rb b/app/models/group.rb index d2fc577acd9..06345c6d1ee 100644 --- a/app/models/group.rb +++ b/app/models/group.rb @@ -392,10 +392,10 @@ class Group < ActiveRecord::Base { :id => TAB_DISCUSSIONS, :label => t("#group.tabs.discussions", "Discussions"), :css_class => 'discussions', :href => :group_discussion_topics_path }, { :id => TAB_COLLECTIONS, :label => t("#group.tabs.collections", "Collections"), :css_class => 'collections', :href => :group_collections_path }, { :id => TAB_CHAT, :label => t("#group.tabs.chat", "Chat"), :css_class => 'chat', :href => :group_chat_path }, + { :id => TAB_FILES, :label => t("#group.tabs.files", "Files"), :css_class => 'files', :href => :group_files_path }, { :id => TAB_PROFILE, :label => t('#tabs.profile', 'Profile'), :css_class => 'profile', :href => :group_profile_path }, ] - available_tabs << { :id => TAB_FILES, :label => t("#group.tabs.files", "Files"), :css_class => 'files', :href => :group_files_path } if context_type == 'Course' available_tabs << { :id => TAB_CONFERENCES, :label => t('#tabs.conferences', "Conferences"), :css_class => 'conferences', :href => :group_conferences_path } if user && self.grants_right?(user, nil, :read) available_tabs << { :id => TAB_SETTINGS, :label => t('#tabs.settings', 'Settings'), :css_class => 'settings', :href => :edit_group_path } if user && grants_right?(user, nil, :manage) available_tabs diff --git a/lib/text_helper.rb b/lib/text_helper.rb index 76fe76b8ee1..6f9e107bb14 100644 --- a/lib/text_helper.rb +++ b/lib/text_helper.rb @@ -66,6 +66,7 @@ module TextHelper # insert placeholders for the links we're going to generate, before we go and escape all the html links = [] placeholder_blocks = [] + message ||= '' message = message.gsub(AUTO_LINKIFY_REGEX) do |match| placeholder_blocks << if match == AUTO_LINKIFY_PLACEHOLDER AUTO_LINKIFY_PLACEHOLDER diff --git a/spec/models/group_spec.rb b/spec/models/group_spec.rb index 3f56e3efc79..52e2a3dbb8a 100644 --- a/spec/models/group_spec.rb +++ b/spec/models/group_spec.rb @@ -488,9 +488,12 @@ describe Group do Group::TAB_PAGES, Group::TAB_PEOPLE, Group::TAB_DISCUSSIONS, + Group::TAB_COLLECTIONS, Group::TAB_CHAT, Group::TAB_FILES, - Group::TAB_CONFERENCES + Group::TAB_PROFILE, + Group::TAB_CONFERENCES, + Group::TAB_SETTINGS ] end @@ -501,9 +504,12 @@ describe Group do Group::TAB_PAGES, Group::TAB_PEOPLE, Group::TAB_DISCUSSIONS, + Group::TAB_COLLECTIONS, Group::TAB_CHAT, Group::TAB_FILES, - Group::TAB_CONFERENCES + Group::TAB_PROFILE, + Group::TAB_CONFERENCES, + Group::TAB_SETTINGS ] end