| 1 |
<?php |
| 2 |
/** |
| 3 |
* Resolver used when no add-on provides subscription groups. |
| 4 |
* |
| 5 |
* @package Forge12\DoubleOptIn\Subscription |
| 6 |
* @since 5.12.0 |
| 7 |
*/ |
| 8 |
|
| 9 |
declare( strict_types=1 ); |
| 10 |
|
| 11 |
namespace Forge12\DoubleOptIn\Subscription; |
| 12 |
|
| 13 |
if ( ! defined( 'ABSPATH' ) ) { |
| 14 |
exit; |
| 15 |
} |
| 16 |
|
| 17 |
final class NullSubscriptionGroupResolver implements SubscriptionGroupResolverInterface { |
| 18 |
|
| 19 |
public function groupForForm( int $formId, string $formRef = '' ): ?SubscriptionGroup { |
| 20 |
return null; |
| 21 |
} |
| 22 |
|
| 23 |
public function findGroup( string $key ): ?SubscriptionGroup { |
| 24 |
return null; |
| 25 |
} |
| 26 |
|
| 27 |
public function groups(): array { |
| 28 |
return array(); |
| 29 |
} |
| 30 |
} |
| 31 |
|