Fix streaming docs
This commit is contained in:
parent
137cf49435
commit
345e8c35c0
@ -24,6 +24,9 @@ class Mastodon(Internals):
|
|||||||
def stream_public(self, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC, local=False, remote=False):
|
def stream_public(self, listener, run_async=False, timeout=_DEFAULT_STREAM_TIMEOUT, reconnect_async=False, reconnect_async_wait_sec=_DEFAULT_STREAM_RECONNECT_WAIT_SEC, local=False, remote=False):
|
||||||
"""
|
"""
|
||||||
Streams public events.
|
Streams public events.
|
||||||
|
|
||||||
|
Set `local` to True to only get local statuses.
|
||||||
|
Set `remote` to True to only get remote statuses.
|
||||||
"""
|
"""
|
||||||
base = '/api/v1/streaming/public'
|
base = '/api/v1/streaming/public'
|
||||||
if local:
|
if local:
|
||||||
@ -50,7 +53,7 @@ class Mastodon(Internals):
|
|||||||
Stream for all public statuses for the hashtag 'tag' seen by the connected
|
Stream for all public statuses for the hashtag 'tag' seen by the connected
|
||||||
instance.
|
instance.
|
||||||
|
|
||||||
Set local to True to only get local statuses.
|
Set `local` to True to only get local statuses.
|
||||||
"""
|
"""
|
||||||
if tag.startswith("#"):
|
if tag.startswith("#"):
|
||||||
raise MastodonIllegalArgumentError("Tag parameter should omit leading #")
|
raise MastodonIllegalArgumentError("Tag parameter should omit leading #")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user