Thanks to visit codestin.com
Credit goes to github.com

Skip to content

plone.api.content.create doesn't adapt behaviors #457

@thet

Description

@thet

When using plone.api.content.create together with Dexterity types which have behaviors with custom behavior factory classes (e.g. with the behavior attribute test123 which sets a marker interface in the behavior factory class instead of an attribute), then content creation leads to unexpected results.
E.g. plone.api.content.create(container, "TestType", "testid", "testtile", test123=True) sets an attribute on the content object instead of a marker interface.

This could be solved when using plone.dexterity.utils.createContentInContainer.

Related:

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions