Skip to content

Commit

Permalink
Use Timex.DateTime.now, rather than Timex.DateTime.today
Browse files Browse the repository at this point in the history
This uses the current time, rather than the beginning of the day
  • Loading branch information
Ryan Bigg committed Oct 5, 2016
1 parent 5a0e779 commit e3d3353
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/aws_auth.ex
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ defmodule AWSAuth do
end

def sign_url(access_key, secret_key, http_method, url, region, service, headers) do
sign_url(access_key, secret_key, http_method, url, region, service, headers, Timex.DateTime.today)
sign_url(access_key, secret_key, http_method, url, region, service, headers, Timex.DateTime.now)
end

def sign_url(access_key, secret_key, http_method, url, region, service, headers, request_time) do
Expand Down Expand Up @@ -74,7 +74,7 @@ defmodule AWSAuth do
end

def sign_authorization_header(access_key, secret_key, http_method, url, region, service, headers, payload) do
sign_authorization_header(access_key, secret_key, http_method, url, region, service, headers, payload, Timex.DateTime.today)
sign_authorization_header(access_key, secret_key, http_method, url, region, service, headers, payload, Timex.DateTime.now)
end

def sign_authorization_header(access_key, secret_key, http_method, url, region, service, headers, payload, request_time) do
Expand Down

0 comments on commit e3d3353

Please sign in to comment.