Skip to content

Commit

Permalink
Merge pull request #8025 from nucleogenesis/add-disable-custom-nav-op…
Browse files Browse the repository at this point in the history
…tion

Add DISABLE_CUSTOM_CHANNEL_NAV - default false to options.py
  • Loading branch information
rtibbles committed Apr 29, 2021
2 parents 98129d4 + 6e5aa01 commit 9af85e8
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
5 changes: 5 additions & 0 deletions kolibri/plugins/learn/kolibri_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@
from kolibri.core.webpack import hooks as webpack_hooks
from kolibri.plugins import KolibriPluginBase
from kolibri.plugins.hooks import register_hook
from kolibri.utils import conf


class Learn(KolibriPluginBase):
untranslated_view_urls = "api_urls"
translated_view_urls = "urls"
kolibri_options = "options"


@register_hook
Expand Down Expand Up @@ -51,6 +53,9 @@ def plugin_data(self):
return {
"allowGuestAccess": get_device_setting("allow_guest_access"),
"allowLearnerUnassignedResourceAccess": allow_learner_unassigned_resource_access(),
"enableCustomChannelNav": conf.OPTIONS["Learn"][
"KOLIBRI_ENABLE_CUSTOM_CHANNEL_NAV"
],
}


Expand Down
9 changes: 9 additions & 0 deletions kolibri/plugins/learn/options.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
option_spec = {
"Learn": {
"KOLIBRI_ENABLE_CUSTOM_CHANNEL_NAV": {
"type": "boolean",
"default": False,
"envvars": ("KOLIBRI_ENABLE_CUSTOM_CHANNEL_NAV",),
},
},
}

0 comments on commit 9af85e8

Please sign in to comment.