This commit closes #11
This commit is contained in:
parent
ba5a0f116c
commit
be8f0262d0
@ -86,8 +86,10 @@
|
|||||||
},
|
},
|
||||||
"caption": {
|
"caption": {
|
||||||
"enabled": false,
|
"enabled": false,
|
||||||
"text": "sample text",
|
"link": null,
|
||||||
"link": null
|
"text": [
|
||||||
|
"sample text"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"submission": {
|
"submission": {
|
||||||
"timeout": 30,
|
"timeout": 30,
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from os import makedirs, path
|
from os import makedirs, path
|
||||||
|
from random import choice
|
||||||
from shutil import rmtree
|
from shutil import rmtree
|
||||||
from traceback import format_exc
|
from traceback import format_exc
|
||||||
from uuid import uuid4
|
from uuid import uuid4
|
||||||
@ -129,9 +130,9 @@ async def send_content(app: PosterClient) -> None:
|
|||||||
|
|
||||||
if configGet("enabled", "caption"):
|
if configGet("enabled", "caption"):
|
||||||
if configGet("link", "caption") != None:
|
if configGet("link", "caption") != None:
|
||||||
caption = f"{caption}[{configGet('text', 'caption')}]({configGet('link', 'caption')})"
|
caption = f"{caption}[{choice(configGet('text', 'caption'))}]({configGet('link', 'caption')})"
|
||||||
else:
|
else:
|
||||||
caption = f"{caption}{configGet('text', 'caption')}"
|
caption = f"{caption}{choice(configGet('text', 'caption'))}"
|
||||||
else:
|
else:
|
||||||
caption = caption
|
caption = caption
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user