Skip to content

Commit b47822c

Browse files
committed
Remove is_dynamic_lut() from views.py
1 parent 3e50fb0 commit b47822c

File tree

1 file changed

+1
-19
lines changed

1 file changed

+1
-19
lines changed

plugin/omero_iviewer/views.py

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
from django.shortcuts import render
1919
from django.http import JsonResponse, Http404
2020
from django.conf import settings
21-
from django.urls import reverse, NoReverseMatch
21+
from django.urls import reverse
2222

2323
from os.path import splitext
2424
from collections import defaultdict
@@ -892,21 +892,3 @@ def shape_stats(request, conn=None, **kwargs):
892892
return JsonResponse({"error": api_exception.message})
893893
except Exception as stats_call_exception:
894894
return JsonResponse({"error": repr(stats_call_exception)})
895-
896-
897-
@login_required()
898-
def is_dynamic_lut(request, **kwargs):
899-
"""
900-
Return true or false for dynamic lut usage URL based on the
901-
current omero-web version.
902-
"""
903-
dynamic_lut = False
904-
try:
905-
# Try to reverse the URL dynamically, which might be version-dependent
906-
_ = reverse("webgateway_luts_png")
907-
dynamic_lut = True
908-
except NoReverseMatch:
909-
# Fallback URL if the dynamic route is not available
910-
pass
911-
# Return the lut_url as JSON
912-
return JsonResponse({'is_dynamic_lut': dynamic_lut})

0 commit comments

Comments
 (0)