From 437f8de643733d850ee6d405b5c49b43910b9111 Mon Sep 17 00:00:00 2001 From: Luna Mendes Date: Tue, 20 Nov 2018 14:48:44 -0300 Subject: [PATCH] run: replace member/banned/target to user in api_index --- run.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/run.py b/run.py index ac6be92..f531937 100644 --- a/run.py +++ b/run.py @@ -231,6 +231,11 @@ async def api_index(app): path = path.replace('>', '}') path = path.replace('int:', '') + # change our parameters into user.id + path = path.replace('member.id', 'user.id') + path = path.replace('banned.id', 'user.id') + path = path.replace('target.id', 'user.id') + methods = rule.methods for method in methods: