diff --git a/django_lostplaces/lostplaces/templates/explorer/profile_update.html b/django_lostplaces/lostplaces/templates/explorer/profile_update.html index d852031..9db8eca 100644 --- a/django_lostplaces/lostplaces/templates/explorer/profile_update.html +++ b/django_lostplaces/lostplaces/templates/explorer/profile_update.html @@ -1,5 +1,6 @@ {% extends 'global.html'%} {% load i18n %} +{% load thumbnail %} {% load widget_tweaks %} # {% block title %}{% trans 'Edit Explorer profile' %}{% endblock %} @@ -34,9 +35,9 @@
- {% if explorer_image_url %} + {% if explorer_image %}
- +
{% endif %}
diff --git a/django_lostplaces/lostplaces/views/explorer_views.py b/django_lostplaces/lostplaces/views/explorer_views.py index 5e0a134..9d9ca3d 100644 --- a/django_lostplaces/lostplaces/views/explorer_views.py +++ b/django_lostplaces/lostplaces/views/explorer_views.py @@ -52,7 +52,7 @@ class ExplorerProfileUpdateView(IsAuthenticatedMixin, View): 'explorer_change_form': ExplorerChangeForm(instance=request.user.explorer) } if request.user.explorer.profile_image: - context['explorer_image_url'] = request.user.explorer.profile_image.url + context['explorer_image'] = request.user.explorer.profile_image return render(request, 'explorer/profile_update.html', context) def post(self, request, *args, **kwargs):