Skip to content

Commit

Permalink
Fix encoding of characters like (
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeal committed Dec 1, 2011
1 parent 00be754 commit a3be5ad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion oauth.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function hmacsign (httpMethod, base_uri, params, consumer_secret, token_secret,
encodeURIComponent( base_uri ) + "&" +
Object.keys(params).sort().map(function (i) {
// big WTF here with the escape + encoding but it's what twitter wants
return encodeURIComponent(qs.escape(i)) + "%3D" + encodeURIComponent(qs.escape(params[i]))
return encodeURIComponent(escape(i)) + "%3D" + encodeURIComponent(escape(params[i]))
}).join("%26")
var key = consumer_secret + '&'
if (token_secret) key += token_secret
Expand Down

0 comments on commit a3be5ad

Please sign in to comment.