From 230f45a76dddec2dabcd3249c43242535d1a469a Mon Sep 17 00:00:00 2001 From: Samuel Gaist <samuel.gaist@idiap.ch> Date: Thu, 26 Apr 2018 14:14:24 +0200 Subject: [PATCH] [algorithms][api] Fix key search in dictionary --- beat/web/algorithms/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/beat/web/algorithms/api.py b/beat/web/algorithms/api.py index bba70cf42..1cae18b5a 100755 --- a/beat/web/algorithms/api.py +++ b/beat/web/algorithms/api.py @@ -177,7 +177,7 @@ def binary(request, author_name, object_name, version=None): if request.user.is_anonymous() or (request.user.username != author_name): return HttpResponseForbidden() - if not request.FILES.has_key('binary'): + if 'binary' not in request.FILES: return HttpResponseBadRequest() file = request.FILES['binary'] -- GitLab