mirror of
https://codeberg.org/rimu/pyfedi
synced 2025-01-23 19:36:56 -08:00
accept alt text
This commit is contained in:
parent
b8227713ea
commit
29f48f58b3
1 changed files with 2 additions and 2 deletions
|
@ -1699,8 +1699,8 @@ def create_post(activity_log: ActivityPubLog, community: Community, request_json
|
||||||
image = File(source_url=request_json['object']['image']['url'])
|
image = File(source_url=request_json['object']['image']['url'])
|
||||||
else:
|
else:
|
||||||
image = File(source_url=post.url)
|
image = File(source_url=post.url)
|
||||||
if alt_text:
|
if alt_text:
|
||||||
image.alt_text = alt_text
|
image.alt_text = alt_text
|
||||||
db.session.add(image)
|
db.session.add(image)
|
||||||
post.image = image
|
post.image = image
|
||||||
elif is_video_url(post.url): # youtube is detected later
|
elif is_video_url(post.url): # youtube is detected later
|
||||||
|
|
Loading…
Add table
Reference in a new issue