Problem/Motivation

Default media icons are stored in public files directory (copied from module path during installation). Public files directory is usually used to store user uploaded files and therefore is not usually versioned. This creates a risk to the project, if the user inadvertently deletes this directory, media icons will not be found and the large file type icon visualization will not work anymore.

Proposed resolution

The solution I propose is to check if this folder exists, before try to use the icons. If the folder is not there, the module will look for the icons in module icons directory.

Remaining tasks

None.

User interface changes

None at this time, but another possible approach would be to make this directory configurable (since the variable is already there).

API changes

None.

Comments

deivamagalhaes’s picture

Title: Default media icons may be lost » Default media icons can be easily deleted and there is no fallback
crystaldawn’s picture

This issue still exists and has been seen in the wild here: https://www.drupal.org/node/2552583 It needs to be addressed.

Chris Matthews’s picture

Version: 7.x-2.0-alpha3 » 7.x-2.x-dev
Status: Active » Closed (outdated)

Recent versions of media have resolved most of peoples concerns and is compatible with entity translation, multilingual and various advanced configurations. Due to the high volume of inactive and most often irrelevant issues we are Closing this as (outdated). If for whatever reason this issue is important to you AND you still have issues after checking the media recipe documentation, then let us know and we will review your concerns.

Otherwise, see the recipe documentation for how to configure media and for troubleshooting tips OR refer to the media_dev distribution if you want to see a working media setup.

As mentioned, feel free to make some noise in this issue if you still feel it is important to you or someone else.

Thanks,

Media team