Skip to content

Allow filter chains to be constructed with instances in the specification - #258

Merged
Ocramius merged 1 commit into
laminas:3.2.xfrom
gsteel:filter-chain-should-allow-instances
Aug 8, 2025
Merged

Allow filter chains to be constructed with instances in the specification#258
Ocramius merged 1 commit into
laminas:3.2.xfrom
gsteel:filter-chain-should-allow-instances

Conversation

@gsteel

@gsteel gsteel commented Aug 8, 2025

Copy link
Copy Markdown
Member

We should be able to create a filter chain with something like:

$chain = new FilterChain($pluginManager, [
    'filters' => [
        [ /** Spec Array */ ],
        new StringTrim(),
    ],
]);

This patch allows instances to given in the spec array and updates the documented types to suit

Relevant to:

laminas/laminas-inputfilter#149

…tion

Signed-off-by: George Steel <george@net-glue.co.uk>
@gsteel gsteel added this to the 3.2.0 milestone Aug 8, 2025
@gsteel
gsteel requested review from a team August 8, 2025 16:03
@Ocramius Ocramius self-assigned this Aug 8, 2025
@Ocramius
Ocramius merged commit 6f52a22 into laminas:3.2.x Aug 8, 2025
15 checks passed
@Ocramius

Ocramius commented Aug 8, 2025

Copy link
Copy Markdown
Member

Thanks @gsteel!

@gsteel
gsteel deleted the filter-chain-should-allow-instances branch August 8, 2025 17:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants