Adds alt text to status images
This commit is contained in:
parent
45a0bd79fd
commit
ff5a0f7bc2
5 changed files with 7 additions and 4 deletions
|
@ -227,7 +227,8 @@ def image_attachments_formatter(images_json):
|
|||
''' deserialize a list of images '''
|
||||
attachments = []
|
||||
for image in images_json:
|
||||
attachment = models.Attachment()
|
||||
caption = image.get('name')
|
||||
attachment = models.Attachment(caption=caption)
|
||||
image_field = image_formatter(image)
|
||||
attachment.image.save(*image_field, save=False)
|
||||
attachments.append(attachment)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue