Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Improvement: Split download_attachment into 2 functions #387

Copy link
Copy link
@herronelou

Description

@herronelou
Issue body actions

Hi.

We often need to download SG thumbnails from the thumbnail's URL.

We wrote code to do that which is essentially duplicated code from sg.download_attachment, the main difference being that instead of passing in an attachment, we directly pass the URL that the function extracts at

url = self.get_attachment_download_url(attachment)

Could we split the code into 2 functions, one to download by URL, and one to download by attachment, as it's essentially the same code?

I can put an MR if you're not against the idea.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.