From 3b753819d3a029a8fc297f33b5a0909b079842de Mon Sep 17 00:00:00 2001 From: Joseph Nuthalapati Date: Mon, 5 Feb 2018 18:14:04 +0530 Subject: [PATCH] api: fix icon_url The django template tag `static` already adds /plinth/static/. The url argument also starts with static which makes it /plinth/static/static/... Signed-off-by: Joseph Nuthalapati Reviewed-by: James Valleroy --- plinth/modules/api/views.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plinth/modules/api/views.py b/plinth/modules/api/views.py index 10626f2c5..d9b945d25 100644 --- a/plinth/modules/api/views.py +++ b/plinth/modules/api/views.py @@ -18,14 +18,14 @@ FreedomBox app for api for android app. """ -from django.http import HttpResponse +import json + from django.core.serializers.json import DjangoJSONEncoder +from django.http import HttpResponse from django.templatetags.static import static -from plinth import frontpage -from plinth import module_loader +from plinth import frontpage, module_loader from plinth.modules import names -import json def access_info(request, **kwargs): @@ -69,4 +69,4 @@ def _get_icon_url(icon_name): if not icon_name: return None - return static('static/theme/icons/{}.png'.format(icon_name)) + return static('theme/icons/{}.png'.format(icon_name))