use v1 API for posting images instead of v2
Apparently even when using the v2 API, which returns image IDs before they're finished processing, you have to wait for them to finish before attaching them to a post, which defeats the purpose. Use v1 API to avoid this.
This commit is contained in:
parent
3ed03eaa83
commit
285610667b
|
@ -107,7 +107,7 @@ class Pleroma:
|
||||||
data.add_field('description', description)
|
data.add_field('description', description)
|
||||||
if focus is not None:
|
if focus is not None:
|
||||||
data.add_field(','.join(map(str, focus)))
|
data.add_field(','.join(map(str, focus)))
|
||||||
return await self.request('POST', '/api/v2/media', data=data)
|
return await self.request('POST', '/api/v1/media', data=data)
|
||||||
|
|
||||||
async def reply(self, to_status, content, *, cw=None):
|
async def reply(self, to_status, content, *, cw=None):
|
||||||
user_id = await self._get_logged_in_id()
|
user_id = await self._get_logged_in_id()
|
||||||
|
|
Loading…
Reference in New Issue