Skip to content

Feature request: Don't set "local.path" as a default filename to prevent it from being detected as a binary #69

@ts-3156

Description

@ts-3156

Thank you for useful gem!

On some systems, a preview of an image is not displayed correctly when I specify "local.path" as a filename. To solve this behavior, could you simply set "file" as a default filename?

If you agree with this issue, I will create a pull request. I would like to know your opinion.


One of those systems is Slack for Mac. Starting at 2021/05/05 05:30 UTC, Slack client no longer correctly displays previews of images when the filename is "local.path".

Expectation Reality
Screenshot 2021-05-07 21 52 06 Screenshot 2021-05-07 21 47 43

The relevant code of this issue is here.
https://github.com/socketry/multipart-post/blob/master/lib/multipart/post/composite_read_io.rb#L80-L88

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions