Skip to content

Commit 510ac7e

Browse files
author
Harold Martin
committed
Added custom user agent to requests
1 parent b71956d commit 510ac7e

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

OX3_Api_Client.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ public function __construct($uri, $email, $password, $consumer_key, $consumer_se
2525
// Set the proxy['adapter'] if $proxy config was passed in
2626
if (!empty($proxy)) {
2727
$proxy['adapter'] = 'Zend_Http_Client_Adapter_Proxy';
28+
$proxy['useragent'] = 'OX3-PHP-API-Client/1.0';
2829
}
2930

3031
// Initilize the cookie jar, from the $cookieJarFile if present

OX3_Api_Wrapper.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
* @package OX_API
99
* @author Harold Martin <[email protected]>
10-
* @version 0.3
10+
* @version 0.4
1111
* @link https://github.com/openx/OX3-PHP-API-Client/tree/wrapper
1212
* @see OX3_Api_Client.php
1313
*/
@@ -68,8 +68,6 @@ public function v1_to_uuid($obj_type, $obj_id) {
6868
}
6969
public function adunit($id)
7070
{
71-
print($id);
72-
error_reporting(E_ALL);
7371
if ($this->v == 3) {
7472
return json_decode($this->client->get(('/a/adunit/'. $id), array('overload' => 'medium'))->getBody(), true);
7573
}

0 commit comments

Comments
 (0)