public function match(RuleScope
$scope): bool
{ if (!
$scope instanceof CheckoutRuleScope
) { return false;
} if (!
$customer =
$scope->
getSalesChannelContext()->
getCustomer()) { return false;
} return $this->shouldCustomerBeCreatedByAdmin ===
(bool) $customer->
getCreatedById();
} public function getConstraints(): array
{ return [ 'shouldCustomerBeCreatedByAdmin' => RuleConstraints::
bool(true
),
];
} public function getConfig(): RuleConfig
{