# give/4.16.9/src/FormMigration/Steps/TermsAndConditions.php

GiveWP – Donation Plugin and Fundraising Platform, version 4.16.9. 23 lines.

- Page: https://pluginprobe.com/plugins/give/4.16.9/code/src/FormMigration/Steps/TermsAndConditions.php
- Raw: https://pluginprobe.com/plugins/give/4.16.9/raw/src/FormMigration/Steps/TermsAndConditions.php
- Modified: 2023-10-16T17:55:46+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/give/4.16.9/code/src/FormMigration/Steps/TermsAndConditions.php#L10-L20`.

```php
<?php

namespace Give\FormMigration\Steps;

use Give\FormMigration\Concerns\Blocks\BlockFactory;;
use Give\FormMigration\Contracts\FormMigrationStep;

class TermsAndConditions extends FormMigrationStep
{
    public function canHandle(): bool
    {
        return $this->formV2->isTermsEnabled();
    }

    public function process()
    {
        $this->fieldBlocks->insertAfter('givewp/payment-gateways', BlockFactory::termsAndConditions([
            'checkboxLabel' => $this->formV2->getTermsAgreementLabel(),
            'agreementText' => $this->formV2->getTermsAgreementText(),
        ]));
    }
}

```
