Skip to content

Itunes categories with same main category are overwritten #41

Open
@podcasthosting

Description

@podcasthosting

Bug Report

Q A
Version(s) 2.14.1

Summary

When setting multiple iTunes categories and two or more having the same "main" category the latter are overwritten.

Current behavior

$feed->setItunesCategories(['Arts' => 'Food]);
$feed->setItunesCategories(['Arts' => 'Visual Arts]);

only

    <itunes:category text="Arts">
      <itunes:category text="Visual Arts"/>
    </itunes:category>

ends up being in the rendered output

How to reproduce

Add two categories with the same main category.

Expected behavior

I´d expect both entries being shown in the feed.

    <itunes:category text="Arts">
      <itunes:category text="Food"/>
    </itunes:category>
    <itunes:category text="Arts">
      <itunes:category text="Visual Arts"/>
    </itunes:category>

The culprit seems to be

vendor/laminas/laminas-feed/src/Writer/Extension/ITunes/Feed.php

somewhere within method setItunesCategories()

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions