// Request Twitter credentials for the user
// @param options {optional}  XXX support options.requestPermissions
// @param credentialRequestCompleteCallback {Function} Callback function to call on
//   completion. Takes one argument, credentialToken on success, or Error on
//   error.
Twitter.requestCredential = function (options, credentialRequestCompleteCallback) {
  // support both (options, callback) and (callback).
  if (!credentialRequestCompleteCallback && typeof options === 'function') {
    credentialRequestCompleteCallback = options;
    options = {};
  }

  var config = ServiceConfiguration.configurations.findOne({service: 'twitter'});
  if (!config) {
    credentialRequestCompleteCallback && credentialRequestCompleteCallback(
      new ServiceConfiguration.ConfigError());
    return;
  }

  var credentialToken = Random.secret();
  // We need to keep credentialToken across the next two 'steps' so we're adding
  // a credentialToken parameter to the url and the callback url that we'll be returned
  // to by oauth provider

  var loginStyle = OAuth._loginStyle('twitter', config, options);

  // url to app, enters "step 1" as described in
  // packages/accounts-oauth1-helper/oauth1_server.js
  var loginPath = '_oauth/twitter/?requestTokenAndRedirect=true'
        + '&state=' + OAuth._stateParam(loginStyle, credentialToken, options && options.redirectUrl);

  if (Meteor.isCordova) {
    loginPath = loginPath + "&cordova=true";
    if (/Android/i.test(navigator.userAgent)) {
      loginPath = loginPath + "&android=true";
    }
  }

  // Support additional, permitted parameters
  var addlParams = Twitter.validParamsAuthenticate;
  for (var i = 0, len = addlParams.length; i < len; i++) {
    if (options && options[addlParams[i]]) {
      loginPath += "&" + addlParams[i] + "=" + encodeURIComponent(options[addlParams[i]]);
    }
  }

  var loginUrl = Meteor.absoluteUrl(loginPath);

  OAuth.launchLogin({
    loginService: "twitter",
    loginStyle: loginStyle,
    loginUrl: loginUrl,
    credentialRequestCompleteCallback: credentialRequestCompleteCallback,
    credentialToken: credentialToken
  });
};

@@ -1609,125 +1609,146 @@
 s%0A  
-var addlParams = Twitter.validParamsAuthenticate;%0A  for (var i = 0, len = addlParams.length; i %3C len; i++
+if (options) %7B%0A    var hasOwn = Object.prototype.hasOwnProperty;%0A    Twitter.validParamsAuthenticate.forEach(function (param
 ) %7B%0A
+  
     if (
 opti
@@ -1747,45 +1747,41 @@
 if (
-options && options%5BaddlParams%5Bi%5D%5D
+hasOwn.call(options, param)
 ) %7B%0A
+  
     
@@ -1801,29 +1801,21 @@
 = %22&%22 + 
-addlParams%5Bi%5D
+param
  + %22=%22 +
@@ -1846,30 +1846,32 @@
 ons%5B
-addlParams%5Bi%5D%5D);%0A    %7D
+param%5D);%0A      %7D%0A    %7D);
 %0A  %7D

Use Array#forEach in twitter_client.js.