Skip to content

Commit

Permalink
Minor changes and fixes, v0.12 milestone
Browse files Browse the repository at this point in the history
  • Loading branch information
elnappo committed Jan 30, 2018
1 parent 262fce4 commit 6b3d2ff
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 10 deletions.
2 changes: 1 addition & 1 deletion nsupdate/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,4 +62,4 @@ def __str__(self):
return version_str


version = Version(0, 13, 0)
version = Version(0, 12, 0)
4 changes: 2 additions & 2 deletions nsupdate/login/urls.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# -*- coding: utf-8 -*-
from django.conf.urls import url
from django.contrib.auth.views import login, logout_then_login, password_reset, password_reset_done, \
from django.contrib.auth.views import login, logout, password_reset, password_reset_done, \
password_reset_confirm, password_reset_complete

urlpatterns = (
# login and logout url
url(r'^login/$', login, {'template_name': 'login.html'}, name='login'),
# or use logout with template 'logout.html'
url(r'^logout/$', logout_then_login, name='logout'),
url(r'^logout/$', logout, name='logout'),

# password reset urls
url(r'^password_reset/$', password_reset, {'template_name': 'password_reset.html'},
Expand Down
4 changes: 2 additions & 2 deletions nsupdate/management/commands/faults.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def add_arguments(self, parser):
dest='flag_abuse',
default=None,
type=int,
help='if client faults N then set abuse flag and reset client faults')
help='if client faults > N then set abuse flag and reset client faults')
parser.add_argument('--notify-user',
action='store_true',
dest='notify_user',
Expand Down Expand Up @@ -119,7 +119,7 @@ def handle(self, *args, **options):
output += u"%s %s\n" % (h.created_by.username, h.get_fqdn(),)
self.stdout.write(output)
if (flag_abuse is not None or reset_client or reset_server or
reset_available or reset_abuse or reset_abuse_blocked):
reset_available or reset_abuse or reset_abuse_blocked):
if flag_abuse is not None:
if h.client_faults > flag_abuse:
h.abuse = True
Expand Down
1 change: 1 addition & 0 deletions nsupdate/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@
REGISTRATION_EMAIL_HTML = False # we override the text, but not the html email template

LOGIN_REDIRECT_URL = '/overview/'
LOGOUT_REDIRECT_URL = '/'

X_FRAME_OPTIONS = 'DENY' # for clickjacking middleware

Expand Down
2 changes: 1 addition & 1 deletion nsupdate/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ def remember_me_login(request, *args, **kw):
if settings.DEBUG:
urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
import debug_toolbar
urlpatterns += (url(r'^__debug__/', include(debug_toolbar.urls)),)
urlpatterns += [url(r'^__debug__/', include(debug_toolbar.urls)), ]
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ all_files = 1
[upload_sphinx]
upload-dir = docs/_build/html

[tool:pytest]
[pytest]
DJANGO_SETTINGS_MODULE = nsupdate.settings.dev
pep8maxlinelength = 120
norecursedirs = .git
Expand Down
3 changes: 0 additions & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
setup for nsupdate package
"""

import sys
PY2 = sys.version_info[0] == 2

from setuptools import setup, find_packages

from nsupdate import version
Expand Down

0 comments on commit 6b3d2ff

Please sign in to comment.