Skip to content

Commit

Permalink
pylint: auto fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
buddhhu committed Jan 31, 2024
1 parent 8368141 commit f525a35
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions plugins/drive.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ async def drive_upload_func(event):
)


@ultroid_cmd("gddl\s+(\S+)(?:\s+-o\s+(\S+))?(?:\s+-f\s+(\S+))?", fullsudo=True)
@ultroid_cmd("gddl\\s+(\\S+)(?:\\s+-o\\s+(\\S+))?(?:\\s+-f\\s+(\\S+))?", fullsudo=True)
async def drive_download_func(event):
"""`{}gddl <link> -o <filename> -f <Folder ID>` - Download file from Google Drive using link.
Args:
Expand All @@ -60,7 +60,7 @@ async def drive_download_func(event):
_ = await drive.download_file(xxx, file_id, filename, folder_id)
filename = _.get("name") or filename
await xxx.edit(f"{filename} downloaded from drive.")


@ultroid_cmd("gdusg$")
async def drive_usage_func(event):
Expand Down Expand Up @@ -114,7 +114,8 @@ async def drive_list_func(event):
if file.get("webContentLink")
else f"Link: {file['webViewLink']}\n"
)
text += f"Size: {humanbytes(file['size'])}\n\n" if file.get("size") else "\n"
text += f"Size: {humanbytes(file['size'])}\n\n" if file.get(
"size") else "\n"
if len(text) > 4096:
with open("drivefiles.txt", "w") as dfiles:
dfiles.write(text)
Expand Down

0 comments on commit f525a35

Please sign in to comment.