jgonyea / grav-plugin-podcast

GravCMS plugin that creates podcast channel and podcast episode page templates along with a podcast RSS feed.
MIT License
18 stars 7 forks source link

No processing in multilang websites #28

Closed leonceaklin closed 4 years ago

leonceaklin commented 4 years ago

The plugin doesn't get the metadata of audio files when the Grav installation has multiple languages enabled.

This is because of line 83 in podcast.php: if (!($obj instanceof \Grav\Common\Page\Page) || $obj->name() != 'podcast-episode.md') {

In my setup, $obj->name() has the value podcast-episode.de.md. You should replace the line with: if (!($obj instanceof \Grav\Common\Page\Page) || $obj->template() != 'podcast-episode') { $obj->template() has always the same value regardless of the language.

In the template files you should change every occurrence of the page.name property to page.template

Thank you!

jgonyea commented 4 years ago

Addressed in ver 2.1.5