Skip to content

Commit dfc87de

Browse files
Update rename.py
1 parent cbdabb2 commit dfc87de

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

utils/rename.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,13 @@ async def example_edit(client: Client, message: Message):
5252
progress_args=(i, t, "`Done, Uploading...`"),
5353
)
5454
await i.delete()
55+
os.remove(r_fname)
5556
else:
5657
await message.edit_text(
5758
"lOl, Atleast reply to file and give new name (with extension ofc) to rename to -_-"
5859
)
5960
except Exception as e:
6061
await message.edit(format_exc(e))
61-
finally:
62-
os.remove(r_fname)
6362

6463

6564
modules_help["rename"] = {

0 commit comments

Comments
 (0)