dev #19

Merged
profitroll merged 98 commits from dev into master 2023-04-24 13:48:22 +03:00
2 changed files with 12 additions and 2 deletions
Showing only changes of commit 64ae3fb047 - Show all commits

View File

@ -49,6 +49,11 @@
"move_sent": false,
"use_interval": false,
"interval": "1h30m",
"submitted_caption": {
"enabled": true,
"ignore_admins": true,
"text": "#submitted"
},
"extensions": {
"photo": [
"jpg",

View File

@ -77,11 +77,16 @@ async def send_content(app: PosterClient) -> None:
else:
caption = ""
if configGet("enabled", "posting", "submitted_caption") and ((submitted["user"] not in app.admins) or (configGet("ignore_admins", "posting", "submitted_caption") is True)):
caption = f"{caption}\n\n{configGet('text', 'posting', 'submitted_caption')}\n"
else:
caption = f"{caption}\n\n"
if configGet("enabled", "caption"):
if configGet("link", "caption") != None:
caption = f"{caption}\n\n[{configGet('text', 'caption')}]({configGet('link', 'caption')})"
caption = f"{caption}[{configGet('text', 'caption')}]({configGet('link', 'caption')})"
else:
caption = f"{caption}\n\n{configGet('text', 'caption')}"
caption = f"{caption}{configGet('text', 'caption')}"
else:
caption = caption