Skip to content

Commit

Permalink
v1.12.0
Browse files Browse the repository at this point in the history
  • Loading branch information
jcberquist committed Aug 31, 2020
1 parent 04d4d8a commit d27319c
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 7 deletions.
7 changes: 6 additions & 1 deletion aws.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,12 @@ component {
struct constructorArgs = { },
struct httpProxy = { server: '', port: 80 }
) {
this.api = new com.api( awsKey, awsSecretKey, defaultRegion, httpProxy );
this.api = new com.api(
awsKey,
awsSecretKey,
defaultRegion,
httpProxy
);

for ( var service in variables.services ) {
if ( structKeyExists( arguments.constructorArgs, service ) ) {
Expand Down
4 changes: 2 additions & 2 deletions box.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@
"URL":"http://opensource.org/licenses/MIT"
}
],
"location":"jcberquist/aws-cfml#v1.11.0",
"location":"jcberquist/aws-cfml#v1.12.0",
"name":"aws-cfml",
"packageDirectory":"awscfml",
"private":false,
"projectURL":"",
"shortDescription":"AWS CFML is a CFML library for interacting with AWS APIs",
"slug":"aws-cfml",
"type":"modules",
"version":"1.11.0"
"version":"1.12.0"
}
14 changes: 11 additions & 3 deletions com/http/coldfusion.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ component {
struct httpProxy = { server: '', port: 80 }
) {
variables.utils = utils;
variables.httpProxy = httpProxy;
return this;
}

Expand All @@ -22,14 +23,21 @@ component {
var request_headers = utils.parseHeaders( headers );
var urlPath = 'http' & ( useSSL ? 's' : '' ) & '://' & fullPath;

cfhttp(url=urlPath, method=httpMethod, result="result", timeout=timeout, proxyserver=httpProxy.server, proxyport=httpProxy.port) {
cfhttp(
url = urlPath,
method = httpMethod,
result = "result",
timeout = timeout,
proxyserver = httpProxy.server,
proxyport = httpProxy.port
) {
for ( var header in request_headers ) {
if ( header.name == 'host' ) continue;
cfhttpparam(type="header", name=lCase( header.name ), value=header.value);
cfhttpparam( type = "header", name = lCase( header.name ), value = header.value );
}

if ( arrayFindNoCase( [ 'POST', 'PUT' ], httpMethod ) && !isNull( arguments.body ) ) {
cfhttpparam(type="body", value=body);
cfhttpparam( type = "body", value = body );
}
}
return result;
Expand Down
9 changes: 8 additions & 1 deletion com/http/lucee.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,14 @@ component {
var request_headers = utils.parseHeaders( headers );
var urlPath = 'http' & ( useSSL ? 's' : '' ) & '://' & fullPath;

http url=urlPath method=httpMethod result="result" encodeurl=false timeout=timeout proxyServer=httpProxy.server proxyPort=httpProxy.port {
http
url=urlPath
method=httpMethod
result="result"
encodeurl=false
timeout=timeout
proxyServer=httpProxy.server
proxyPort=httpProxy.port {
for ( var header in request_headers ) {
if ( header.name == 'host' ) continue;
httpparam type="header" name=lCase( header.name ) value=header.value;
Expand Down

0 comments on commit d27319c

Please sign in to comment.