Skip to content

Commit

Permalink
fix for duplicate data
Browse files Browse the repository at this point in the history
  • Loading branch information
gwoo committed Jun 12, 2010
1 parent 218ceec commit 9659529
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions extensions/service/Oauth.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,20 +57,6 @@ public function __construct($config = array()) {
parent::__construct($config);
}

/**
* Initialize classes to be used
*
* @return void
*/
public function _init() {
parent::_init();
$config = $this->_config;

if (!empty($config['proxy'])) {
$config['host'] = $config['proxy'];
}
}

/**
* If a key is set returns the value of that key
* Without a key it will return config array
Expand Down Expand Up @@ -110,10 +96,12 @@ public function send($method, $path = null, $data = array(), array $options = ar
$header = 'OAuth realm="' . $options['realm'] . '",';
foreach ($oauth as $key => $val) {
$header .= $key . '="' . rawurlencode($val) . '",';
unset($oauth[$key]);
}
$options['headers'] = array('Authorization' => $header);
}
$data += $oauth;

$response = parent::send($method, $url, $data, $options);

if (strpos($response, 'oauth_token=') !== false) {
Expand Down

0 comments on commit 9659529

Please sign in to comment.