mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-01-21 07:55:00 +00:00
Minor PEP8 & spelling fixes in various modules
This commit is contained in:
parent
711892486e
commit
f04e1c1657
@ -23,8 +23,8 @@ from plinth import cfg
|
||||
|
||||
def init():
|
||||
"""Initailize the apps module"""
|
||||
cfg.main_menu.add_urlname(_('Apps'), 'glyphicon-download-alt', 'apps:index',
|
||||
80)
|
||||
cfg.main_menu.add_urlname(_('Apps'), 'glyphicon-download-alt',
|
||||
'apps:index', 80)
|
||||
|
||||
|
||||
def index(request):
|
||||
|
||||
@ -226,7 +226,7 @@ def _apply_changes(request, old_status, new_status):
|
||||
request.session[translation.LANGUAGE_SESSION_KEY] = language
|
||||
except Exception as exception:
|
||||
messages.error(request, _('Error setting language: {exception}')
|
||||
.format(exception=exception))
|
||||
.format(exception=exception))
|
||||
else:
|
||||
messages.success(request, _('Language changed'))
|
||||
|
||||
|
||||
@ -26,7 +26,7 @@ import plinth.service as service_module
|
||||
|
||||
|
||||
def index(request):
|
||||
"""Serve introcution page"""
|
||||
"""Serve introduction page"""
|
||||
if not firewall.get_enabled_status():
|
||||
return TemplateResponse(request, 'firewall.html',
|
||||
{'title': firewall.title,
|
||||
|
||||
@ -20,7 +20,6 @@ Help module for Plinth.
|
||||
"""
|
||||
|
||||
import os
|
||||
from gettext import gettext as _
|
||||
from django.http import Http404
|
||||
from django.template.response import TemplateResponse
|
||||
from django.utils.translation import ugettext as _, ugettext_lazy
|
||||
|
||||
@ -116,7 +116,7 @@ def _collect_setup_result(request):
|
||||
return_code = setup_process.poll()
|
||||
|
||||
# Setup process is not complete yet
|
||||
if return_code == None:
|
||||
if return_code is None:
|
||||
return
|
||||
|
||||
if not return_code:
|
||||
|
||||
@ -108,7 +108,7 @@ def _collect_config_result(request):
|
||||
return_code = config_process.poll()
|
||||
|
||||
# Config process is not complete yet
|
||||
if return_code == None:
|
||||
if return_code is None:
|
||||
return
|
||||
|
||||
status = tor.get_status()
|
||||
|
||||
@ -67,5 +67,3 @@ def _diagnose_ldap_entry(search_item):
|
||||
|
||||
return [_('Check LDAP entry "{search_item}"')
|
||||
.format(search_item=search_item), result]
|
||||
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user