Conditional action in Kirby Uniform

Hi,

I am using Uniform for a form submission, and want to run an action only if a checkbox in the form is checked. So I have something like this:

$form->honeypotGuard()->honeytimeGuard(...)->emailAction(...)->webhookAction(...)->done();

But only want to run the webhookAction if the checkbox is checked (it is a mailing list signup). What is the best way of doing this?

I don’t think you have to chain the actions, but can add them one at a time, and therefore conditionally.

You are absolutely right, I thought they had to be chained. Thanks for the pointer