diff options
Diffstat (limited to 'mastodon/streaming_endpoints.py')
-rw-r--r-- | mastodon/streaming_endpoints.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mastodon/streaming_endpoints.py b/mastodon/streaming_endpoints.py index 9ff72f5..fc705e6 100644 --- a/mastodon/streaming_endpoints.py +++ b/mastodon/streaming_endpoints.py | |||
@@ -46,7 +46,7 @@ class Mastodon(Internals): | |||
46 | base = '/api/v1/streaming/hashtag' | 46 | base = '/api/v1/streaming/hashtag' |
47 | if local: | 47 | if local: |
48 | base += '/local' | 48 | base += '/local' |
49 | return self.__stream("{}?tag={}".format(base, tag), listener, run_async=run_async, timeout=timeout, reconnect_async=reconnect_async, reconnect_async_wait_sec=reconnect_async_wait_sec) | 49 | return self.__stream(f"{base}?tag={tag}", listener, run_async=run_async, timeout=timeout, reconnect_async=reconnect_async, reconnect_async_wait_sec=reconnect_async_wait_sec) |
50 | 50 | ||
51 | @api_version("2.1.0", "2.1.0", _DICT_VERSION_STATUS) | 51 | @api_version("2.1.0", "2.1.0", _DICT_VERSION_STATUS) |
52 | def stream_list(self, id, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC): | 52 | def stream_list(self, id, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC): |
@@ -55,7 +55,7 @@ class Mastodon(Internals): | |||
55 | list. | 55 | list. |
56 | """ | 56 | """ |
57 | id = self.__unpack_id(id) | 57 | id = self.__unpack_id(id) |
58 | return self.__stream("/api/v1/streaming/list?list={}".format(id), listener, run_async=run_async, timeout=timeout, reconnect_async=reconnect_async, reconnect_async_wait_sec=reconnect_async_wait_sec) | 58 | return self.__stream(f"/api/v1/streaming/list?list={id}", listener, run_async=run_async, timeout=timeout, reconnect_async=reconnect_async, reconnect_async_wait_sec=reconnect_async_wait_sec) |
59 | 59 | ||
60 | @api_version("2.6.0", "2.6.0", _DICT_VERSION_STATUS) | 60 | @api_version("2.6.0", "2.6.0", _DICT_VERSION_STATUS) |
61 | def stream_direct(self, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC): | 61 | def stream_direct(self, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC): |