mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-11-29 08:25:10 +00:00
Fix some Django deprecations
- Use simple_tag() instead of assignment_tag(). Assignments with simple_tag() works just like before. - When loading urls for application, specify application name during inclusion. - Use the reverse() method from django.urls which as moved from django.core.urlresolvers. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
1 parent
7540266a29
commit
b8adb19e8b
3 files changed
+3
-3
No files matched your search
@@ -21,7 +21,7 @@ from plinth.modules.pagekite import utils
|
||||
register = template.Library()
|
||||
|
||||
|
||||
@register.assignment_tag
|
||||
@register.simple_tag
|
||||
def create_pagekite_service_url(service, kite_name):
|
||||
"""Create a URL out of a pagekite service
|
||||
|
||||
|
||||
@@ -20,9 +20,9 @@ Views for snapshot module.
|
||||
"""
|
||||
|
||||
from django.contrib import messages
|
||||
from django.core.urlresolvers import reverse
|
||||
from django.shortcuts import redirect
|
||||
from django.template.response import TemplateResponse
|
||||
from django.urls import reverse
|
||||
from django.utils.translation import ugettext as _
|
||||
import json
|
||||
|
||||
|
||||
Reference in new issue
Block a user