mirror of
https://github.com/netbox-community/netbox.git
synced 2026-04-19 15:31:35 +02:00
Merge branch 'main' into feature
This commit is contained in:
@@ -57,8 +57,7 @@ def is_api_request(request):
|
||||
"""
|
||||
Return True of the request is being made via the REST API.
|
||||
"""
|
||||
api_path = reverse('api-root')
|
||||
return request.path_info.startswith(api_path) and request.content_type == HTTP_CONTENT_TYPE_JSON
|
||||
return request.path_info.startswith(reverse('api-root'))
|
||||
|
||||
|
||||
def is_graphql_request(request):
|
||||
|
||||
Reference in New Issue
Block a user