diff --git a/db/migrations/1.314_step_00349.php b/db/migrations/1.314_step_00349.php index 73803ab40b6a86a6f53992c9af2ae932e95fc81f..8ae412340f5de6ab20dae589e67ee23e247e442b 100644 --- a/db/migrations/1.314_step_00349.php +++ b/db/migrations/1.314_step_00349.php @@ -157,6 +157,13 @@ class Step00349 extends Migration foreach ($db->query("SELECT institut_id, type, modules FROM Institute") as $row) { $activated_plugins = $db->fetchPairs("SELECT plugins_activated.pluginid, state FROM `plugins_activated` INNER JOIN `plugins` USING(pluginid) WHERE range_id=? AND range_type='inst' ORDER BY navigationpos", [$row['institut_id']]); + //activate blubber if thread exists, biest-363 + if (!isset($activated_plugins[$all_plugins['Blubber']])) { + $blubb_exists = $db->fetchColumn("SELECT 1 FROM blubber_threads WHERE context_id = ?", [$row['institut_id']]); + if ($blubb_exists) { + $activated_plugins[$all_plugins['Blubber']] = '1'; + } + } $modules = $this->getLocalModules('inst', $row['modules'], $row['type']); $pos = 0; foreach ($modules as $pos => $module) { @@ -368,7 +375,7 @@ class OldSemClass implements ArrayAccess $slots = [ 'overview' => 'CoreOverview', 'admin' => 'CoreAdmin', - 'forum' => 'Blubber', + 'forum' => 'CoreForum', 'documents' => 'CoreDocuments', 'scm' => 'CoreScm', 'wiki' => 'CoreWiki', diff --git a/lib/classes/SemClass.class.php b/lib/classes/SemClass.class.php index bf49076f5b82de6dc11ac325624b61b2ef7755ad..f4ef3da8d83de0fb6cd21ebe243413a84f0e29b1 100644 --- a/lib/classes/SemClass.class.php +++ b/lib/classes/SemClass.class.php @@ -86,7 +86,7 @@ class SemClass implements ArrayAccess 'admin' => 'CoreAdmin' // always available ]; $slots = [ - 'forum' => 'Blubber', + 'forum' => 'CoreForum', 'documents' => 'CoreDocuments', 'scm' => 'CoreScm', 'wiki' => 'CoreWiki',