From 84845f429f6a7fdb6853bb42d9d756d6a5fa50ee Mon Sep 17 00:00:00 2001 From: William Pitcock Date: Mon, 18 Feb 2019 05:09:05 +0000 Subject: [PATCH] services: api service: add media description support --- src/services/api/api.service.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/services/api/api.service.js b/src/services/api/api.service.js index 13d31d91..824713a0 100644 --- a/src/services/api/api.service.js +++ b/src/services/api/api.service.js @@ -424,7 +424,7 @@ const unretweet = ({ id, credentials }) => { }) } -const postStatus = ({credentials, status, spoilerText, visibility, sensitive, mediaIds, inReplyToStatusId, contentType, noAttachmentLinks}) => { +const postStatus = ({credentials, status, spoilerText, visibility, sensitive, mediaIds, inReplyToStatusId, contentType, noAttachmentLinks, mediaDescriptions}) => { const idsText = mediaIds.join(',') const form = new FormData() @@ -435,6 +435,7 @@ const postStatus = ({credentials, status, spoilerText, visibility, sensitive, me if (visibility) form.append('visibility', visibility) if (sensitive) form.append('sensitive', sensitive) if (contentType) form.append('content_type', contentType) + form.append('descriptions', JSON.stringify(mediaDescriptions)) form.append('media_ids', idsText) if (inReplyToStatusId) { form.append('in_reply_to_status_id', inReplyToStatusId)