Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mimetypes in the trashbin are wrong #1337

Closed
MorrisJobke opened this issue Sep 9, 2016 · 3 comments · Fixed by #1346
Closed

Mimetypes in the trashbin are wrong #1337

MorrisJobke opened this issue Sep 9, 2016 · 3 comments · Fixed by #1346

Comments

@MorrisJobke
Copy link
Member

  • all mimetypes in the trashbin are of type application/octet-stream
  • I guess this is because they end with .dUNIXTIMESTAMP

Any idea how to fix that? cc @schiessle @icewind1991 @rullzer

I found this while debugging another issue.

@MorrisJobke
Copy link
Member Author

MorrisJobke commented Sep 9, 2016

To check that just put a file with mimetype (e.g. text file) into the trashbin and check the response of the request to apps/files_trashbin/ajax/list.php:

{
    "data": {
        "directory": "/",
        "files": [
            {
                "etag": 1473409022000,
                "id": 0,
                "mimetype": "application/octet-stream",
                "mtime": 1473409022000,
                "name": "abc.def.txt",
                "parentId": null,
                "permissions": 1,
                "size": 3,
                "type": "file"
            },
            {
                "etag": 1473408408000,
                "id": 1,
                "mimetype": "application/octet-stream",
                "mtime": 1473408408000,
                "name": "test.docx",
                "parentId": null,
                "permissions": 1,
                "size": 0,
                "type": "file"
            }
        ],
        "permissions": 0
    },
    "status": "success"
}

@schiessle
Copy link
Member

I remember that back then when I wrote the code I explicitly removed the .d4347364783 for the mime type detection. Seems that we lost it at some point in time again... I will have a look.

@schiessle
Copy link
Member

Here we broke it... 435cd31

I will revert the line for the mimetype detection

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants