Commit 2f0206ed authored by Manfred Kutas's avatar Manfred Kutas

Merge pull request #15 in ZP/z-push from bugfix/ZP-651-wp-does-not-set-http_user_agent to develop

* commit 'd15b4438':
  ZP-651 #comment use DeviceType if UserAgent is not available
parents 8f0ed00c d15b4438
...@@ -167,7 +167,7 @@ class BackendZarafa implements IBackend, ISearchProvider { ...@@ -167,7 +167,7 @@ class BackendZarafa implements IBackend, ISearchProvider {
// send Z-Push version and user agent to ZCP - ZP-589 // send Z-Push version and user agent to ZCP - ZP-589
if (Utils::CheckMapiExtVersion('7.2.0')) { if (Utils::CheckMapiExtVersion('7.2.0')) {
$zpush_version = 'Z-Push_' . @constant('ZPUSH_VERSION'); $zpush_version = 'Z-Push_' . @constant('ZPUSH_VERSION');
$user_agent = $_SERVER['HTTP_USER_AGENT']; $user_agent = (Request::GetUserAgent() != Request::UNKNOWN) ? Request::GetUserAgent() : Request::GetDeviceType();
$this->session = @mapi_logon_zarafa($user, $pass, MAPI_SERVER, null, null, 0, $zpush_version, $user_agent); $this->session = @mapi_logon_zarafa($user, $pass, MAPI_SERVER, null, null, 0, $zpush_version, $user_agent);
} }
else { else {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment