mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-01-28 08:03:36 +00:00
tiny docstring, import and trailing slash change
This commit is contained in:
parent
a82a83576f
commit
50f657fbc5
2
menu.py
2
menu.py
@ -69,7 +69,7 @@ class Menu(object):
|
||||
return request_path.startswith(self.url)
|
||||
|
||||
def active_item(self, request):
|
||||
"""Return the first active item that is found"""
|
||||
"""Return the first active item (e.g. submenu) that is found"""
|
||||
for item in self.items:
|
||||
if request.path.startswith(item.url):
|
||||
return item
|
||||
|
||||
@ -8,9 +8,9 @@ import cfg
|
||||
|
||||
def init():
|
||||
"""Initialize the Help module"""
|
||||
menu = cfg.main_menu.add_item(_('Documentation'), 'icon-book', '/help',
|
||||
101)
|
||||
menu.add_item(_("Where to Get Help"), "icon-search", "/help/index/", 5)
|
||||
menu = cfg.main_menu.add_item(_('Documentation'), 'icon-book',
|
||||
'/help/index', 101)
|
||||
menu.add_item(_("Where to Get Help"), "icon-search", "/help/index", 5)
|
||||
menu.add_item(_('Developer\'s Manual'), 'icon-info-sign',
|
||||
'/help/page/plinth', 10)
|
||||
menu.add_item(_('FAQ'), 'icon-question-sign', '/help/page/faq', 20)
|
||||
|
||||
6
views.py
6
views.py
@ -19,12 +19,12 @@
|
||||
Main Plinth views
|
||||
"""
|
||||
|
||||
from django.core.urlresolvers import reverse
|
||||
from django.http.response import HttpResponseRedirect
|
||||
import logging
|
||||
|
||||
import cfg
|
||||
from withsqlite.withsqlite import sqlite_db
|
||||
from django.http.response import HttpResponseRedirect
|
||||
from django.core.urlresolvers import reverse
|
||||
import cfg
|
||||
|
||||
|
||||
LOGGER = logging.getLogger(__name__)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user