Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ async def download_insta(command, m, dir):
if output:
datetime_ist = datetime.now(IST)
ISTIME = datetime_ist.strftime("%I:%M:%S %p - %d %B %Y")
msg="CURRENT_STATUS ⚙️ : <code>{}</code>\nLast Updated :<code>{}</code>".format(output.decode("UTF8"), ISTIME)
msg = f'CURRENT_STATUS ⚙️ : <code>{output.decode("UTF8")}</code>\nLast Updated :<code>{ISTIME}</code>'
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Function download_insta refactored with the following changes:

msg=msg.replace(f'{dir}/', 'DOWNLOADED : ')
try:
await m.edit(msg)
Expand All @@ -65,7 +65,7 @@ async def download_insta(command, m, dir):
if error:
datetime_ist = datetime.now(IST)
ISTIME = datetime_ist.strftime("%I:%M:%S %p - %d %B %Y")
ermsg="ERROR ❌ : <code>{}</code>\nLast Updated : <code>{}</code>".format(error.decode("UTF8"), ISTIME)
ermsg = f'ERROR ❌ : <code>{error.decode("UTF8")}</code>\nLast Updated : <code>{ISTIME}</code>'
try:
await m.edit(ermsg)
except:
Expand Down