From e4d0b6c17e0c0aeea2a731642f4fd6c4c55310e6 Mon Sep 17 00:00:00 2001 From: Maxime Alves LIRMM Date: Fri, 24 Jul 2020 18:27:20 +0200 Subject: [PATCH] handle "/" routes --- halfapi/cli.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/halfapi/cli.py b/halfapi/cli.py index 9777977..f495cd0 100755 --- a/halfapi/cli.py +++ b/halfapi/cli.py @@ -89,8 +89,8 @@ def dbupdate(domain): def get_fct_name(http_verb, path): if path[0] != '/': raise Exception('Malformed path') - - elts = path[1:].split('/') + + elts = [] if len(path) == 1 else path[1:].split('/') fct_name = [http_verb.lower()] for elt in elts: