Now I must admit this bug is a bit of an outside case. Usually there wouldn't be much call to use the media_gallery module but change the field formatter on the gallery media field of the gallery content type to one other than the default.

However, there is code in the module that seems to make assumptions on the fact. If I want to switch to a different field formatter the media_gallery_node_view_alter() doesn't check the formatter being used before trying to set #file and #contextual_links on the build array. Similarly if I want to use the Media gallery formatter on a different content type it will not work.

I don't know if this is intended but ideally I would prefer the implementation of hook_node_view_alter() was tied closer to the formatter than the bundle type.

Comments

rickvug’s picture

subscribe.

Ravi.J’s picture

subscribe

lsolesen’s picture

Status: Active » Postponed (maintainer needs more info)

Found a solution

lsolesen’s picture

Status: Postponed (maintainer needs more info) » Fixed

No activity.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

fix typo