private function addAffiliateTracking(Cart
$cart, DataBag
$data): void
{ $affiliateCode =
$data->
get(OrderService::AFFILIATE_CODE_KEY
);
$campaignCode =
$data->
get(OrderService::CAMPAIGN_CODE_KEY
);
if ($affiliateCode) { $cart->
setAffiliateCode($affiliateCode);
} if ($campaignCode) { $cart->
setCampaignCode($campaignCode);
} }}