Closed (fixed)
Project:
File Entity (fieldable files)
Version:
7.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
26 Jan 2015 at 17:33 UTC
Updated:
15 Dec 2018 at 05:29 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
agupta commented^^ also the max file size isn't honored.
Comment #2
hussainwebI am updating the title for accuracy. I am also moving the other issue for parent to related list. Strictly speaking, that is not the reason why this bug came up. You wouldn't notice it earlier because the file extension was essentially locked to the already uploaded file.
This bug actually belongs to the media module (you are probably using that widget). There is no option to replace the file using the generic file widget. However, I am leaving this issue here as the fix would have to go in both the places. I think the way forward would be to match the behavior of upload file where the settings from field instance are shown correctly. When you click edit, these settings are not used and file_entity module uses the extension from the file type. It does not even check the upload size limit. I will work on a patch for the file_entity module in this issue and open a new issue in media module for it's patch.
Comment #3
hussainwebI have already uploaded the required patch for media module in #2562483-2: File validation settings are not used when editing a file. This is the patch required for file_entity to actually set the options on the file upload element. Both these patches are required for this to work. I have tested this against my setup and found that both extensions and file size settings are correctly shown when editing a file.
Comment #5
hussainwebFixing the failures (which were just notices).
Comment #6
joseph.olstadre-triggered tests, not sure if this patch still applies
Comment #8
joseph.olstadtestbot had a glitch, is fixed now, need to re-trigger the tests.
Comment #9
kristen polI reviewed the code and the changes seem pretty clear and I don't see any code standards issues.
I tested on simplytest.me and it appears to work as expected. I did the following based on the issue summary instructions:
Comment #10
kristen polComment #13
joseph.olstad