Skip to content
This repository has been archived by the owner on Aug 7, 2024. It is now read-only.

Commit

Permalink
mini fix media_category to postUpdate and simple upload file
Browse files Browse the repository at this point in the history
  • Loading branch information
nxexox committed Feb 5, 2018
1 parent 2f896ec commit 438be01
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions twitter/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -1098,9 +1098,13 @@ def PostUpdate(self,
else:
_, _, file_size, media_type = parse_media_file(media)
if file_size > self.chunk_size or media_type in chunked_types:
media_ids.append(self.UploadMediaChunked(media, media_additional_owners))
media_ids.append(self.UploadMediaChunked(
media, media_additional_owners, media_category=media_category
))
else:
media_ids.append(self.UploadMediaSimple(media, media_additional_owners))
media_ids.append(self.UploadMediaSimple(
media, media_additional_owners, media_category=media_category
))
parameters['media_ids'] = ','.join([str(mid) for mid in media_ids])

if latitude is not None and longitude is not None:
Expand Down

0 comments on commit 438be01

Please sign in to comment.