Im using the media module and in admin/config/media/file-types/manage/video/file-display I get the error message:

Notice: Undefined index: default_formatter in editablefields_field_formatter_default_settings() (line 159 of /var/www/vhosts/localhost/httpdocs/sites/all/modules/editablefields/editablefields.module).
Notice: Undefined index: module in editablefields_field_formatter_settings_form() (line 119 of /var/www/vhosts/localhost/httpdocs/sites/all/modules/editablefields/editablefields.module).

How can this be fixed?

Comments

aasarava’s picture

Just wanted to say that yes, I'm seeing the same problem.

lukus’s picture

I'm getting the same problem here.

froeser’s picture

Hi, I'm getting a similar problem:

Notice: Undefined index: module in editablefields_fallback_formatter() (line 173 of [patthToRootDirectory]/modules/editablefields/editablefields.module).

Don't quite know if this is a new problem or the same as described above.

johnv’s picture

Title: Error: Notice: Undefined index: default_formatter in editablefields_field_formatter_default_settings() » Media field generates Notice: Undefined index: default_formatter in editablefields_field_formatter_default_settings()

I guess this is only for fields from Media module?
Is this still happening with a newer release of Media?

Yuri’s picture

still happening ...

johnv’s picture

Title: Media field generates Notice: Undefined index: default_formatter in editablefields_field_formatter_default_settings() » Notice: Undefined index: default_formatter in editablefields_field_formatter_default_settings() with 'Media Field'
Status: Active » Closed (duplicate)
johnv’s picture

Issue summary: View changes

error

OnkelTem’s picture

Version: 7.x-1.0-alpha1 » 7.x-1.x-dev
Issue summary: View changes
Status: Closed (duplicate) » Active
StatusFileSize
new1.94 KB

I'm not sure this is duplicate as the issue being referenced is about disabling some modules (and lacking formatters).
The real reason of this message is that file_entity module reuses field formatter functions by calling hook_field_formatter_settings_form() but doesn't really work with Field API, mocking $parameters and passing NULL as $field. But editablefields_field_formatter_settings_form() and other editablefields functions doesn't expect $field to be NULL.

Please try this simple patch, which avoids doing anything when $field IS NULL.

skylord’s picture

Works OK! Thanks!

josebc’s picture

Status: Active » Reviewed & tested by the community

patch works

joelpittet’s picture

Status: Reviewed & tested by the community » Postponed (maintainer needs more info)

It's not this module is it? https://www.drupal.org/project/mediafield

skylord’s picture

joelpittet’s picture

Status: Postponed (maintainer needs more info) » Needs work

Thanks I was able to reproduce the error on simplytest.me. The patch needs a bit of clean up, the nested if is not necessary, and just a bit more tidying. I'll do it soon and commit it unless someone else wants to tackle that?

sokru’s picture

Status: Needs work » Needs review
StatusFileSize
new1.37 KB

Reroll and tidying.