Skip to content

Commit 576baad

Browse files
authored
Merge pull request #22 from synolia/master
More details in UserAgent
2 parents a5e20d8 + faec8c8 commit 576baad

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/Service/Gateway.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ class Gateway
3030
{
3131
const FIRST_NAME_LAST_NAME_MAX_LENGTH = 100;
3232
const USER_AGENT_PRODUCT_NAME = 'PayPlug-OroCommerce';
33+
const USER_AGENT_OROCOMMERCE_VERSION_PREFIX = 'OroCommerce/';
34+
const PAYPLUG_MODULE_COMPOSER_NAME = 'payplug/payplug-orocommerce';
3335

3436
/**
3537
* @var DoctrineHelper
@@ -230,7 +232,8 @@ protected function initPayplugClientAndSetDebugModeForLogger(PayplugConfigInterf
230232

231233
HttpClient::addDefaultUserAgentProduct(
232234
self::USER_AGENT_PRODUCT_NAME,
233-
$this->versionHelper->getVersion()
235+
$this->versionHelper->getVersion(self::PAYPLUG_MODULE_COMPOSER_NAME),
236+
self::USER_AGENT_OROCOMMERCE_VERSION_PREFIX . $this->versionHelper->getVersion()
234237
);
235238

236239
return $client;

0 commit comments

Comments
 (0)