Skip to content

CarbonPeriod is copied as DatePeriod #201

@alexz707

Description

@alexz707

With the new filter in place, a CarbonPeriod will be treated like a DatePeriod object because it is inherited from DatePeriod.
But as the filter creates and returns a new DatePeriod it's not a copy anymore.

The first idea was to make the filter generic but I'm not sure if all objects which inherit from DatePeriod would have the same constructor.

The second idea was to add a specific filter but it needs to be before the DatePeriod filter.
As there is already a prependFilter but not a prependTypeFilter function I've created a PR.

Best
Alex

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions