Use single quotes for simple strings.

This commit is contained in:
Gary Jones 2012-11-18 01:32:38 +00:00
parent bebf65bfed
commit 36add4e946
2 changed files with 4 additions and 6 deletions

View File

@ -12,7 +12,7 @@ class HmacSha1 extends SignatureMethod
{ {
public function getName() public function getName()
{ {
return "HMAC-SHA1"; return 'HMAC-SHA1';
} }
public function buildSignature($request, $consumer, $token) public function buildSignature($request, $consumer, $token)
@ -22,7 +22,7 @@ class HmacSha1 extends SignatureMethod
$key_parts = array( $key_parts = array(
$consumer->secret, $consumer->secret,
($token) ? $token->secret : "" ($token) ? $token->secret : ''
); );
$key_parts = Util::urlencodeRfc3986($key_parts); $key_parts = Util::urlencodeRfc3986($key_parts);

View File

@ -23,10 +23,8 @@ class Token
*/ */
public function toString() public function toString()
{ {
return "oauth_token=" . return 'oauth_token=' . Util::urlencodeRfc3986($this->key) .
Util::urlencodeRfc3986($this->key) . '&oauth_token_secret=' . Util::urlencodeRfc3986($this->secret);
"&oauth_token_secret=" .
Util::urlencodeRfc3986($this->secret);
} }
public function __toString() public function __toString()