From b113a81a04ec994ca5304d2f7dd9c92fcfa4255b Mon Sep 17 00:00:00 2001 From: retoor Date: Wed, 27 Nov 2024 19:32:36 +0000 Subject: [PATCH] fix: correct vote string from empty to "-1" in voting component --- src/ragnar/api.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ragnar/api.py b/src/ragnar/api.py index fc8a215..e235c21 100644 --- a/src/ragnar/api.py +++ b/src/ragnar/api.py @@ -60,15 +60,15 @@ class Api: obj = json.loads(response.text) return obj - def post_rant_vote(self, id, vote): + def post_rant_vote(self, id_, vote): response = requests.post( - self.base_url + "devrant/rants/" + str(id) + "/vote", + self.base_url + "devrant/rants/" + str(id_) + "/vote", data={ "app": 3, "user_id": self.auth["user_id"], "token_id": self.auth["token_id"], "token_key": self.auth["token_key"], - "vote": vote, + "vote": str(vote), # "plat": 3, }, )