.getProperty(OAuth1ClientSupport.OAUTH_PROPERTY_OAUTH_PARAMETERS);
} else {
request.removeProperty(OAuth1ClientSupport.OAUTH_PROPERTY_OAUTH_PARAMETERS);
}
OAuth1Secrets secrets = (OAuth1Secrets) request.getProperty(OAuth1ClientSupport.OAUTH_PROPERTY_OAUTH_SECRETS);
if (secrets == null) {
secrets = (OAuth1Secrets) request.getConfiguration().getProperty(OAuth1ClientSupport.OAUTH_PROPERTY_OAUTH_SECRETS);
} else {
request.removeProperty(OAuth1ClientSupport.OAUTH_PROPERTY_OAUTH_SECRETS);
}
if (request.getHeaders().containsKey("Authorization")) {
return;
}
// Make modifications to clones.
final OAuth1Parameters paramCopy = parameters.clone();
final OAuth1Secrets secretsCopy = secrets.clone();
checkParametersConsistency(paramCopy, secretsCopy);
if (consumerFromProperties != null) {
paramCopy.consumerKey(consumerFromProperties.getConsumerKey());
secretsCopy.consumerSecret(consumerFromProperties.getConsumerSecret());
}
if (tokenFromProperties != null) {
paramCopy.token(tokenFromProperties.getToken());
secretsCopy.tokenSecret(tokenFromProperties.getAccessTokenSecret());
}
if (paramCopy.getTimestamp() == null) {
paramCopy.setTimestamp();
}