From 80e711a3a1ef9c1b6d7ff045b2e1701e910b0517 Mon Sep 17 00:00:00 2001 From: Daniel Schwarz Date: Wed, 15 Feb 2023 21:50:50 -0500 Subject: [PATCH] Fixed type error in vote method signature --- toot/api.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/toot/api.py b/toot/api.py index 9d46e23..795492b 100644 --- a/toot/api.py +++ b/toot/api.py @@ -1,4 +1,5 @@ import re +from typing import List import uuid from urllib.parse import urlparse, urlencode, quote @@ -361,7 +362,7 @@ def whois(app, user, account): return http.get(app, user, f'/api/v1/accounts/{account}').json() -def vote(app, user, poll_id, choices: list[int]): +def vote(app, user, poll_id, choices: List[int]): url = f"/api/v1/polls/{poll_id}/votes" json = {'choices': choices} return http.post(app, user, url, json=json).json()