From b7cf10e02b6a1715f60a81f1c0e062257a421302 Mon Sep 17 00:00:00 2001 From: technoweenie Date: Fri, 4 Jan 2013 11:56:55 -0700 Subject: [PATCH] memoize these class methods. no reason to regenerate these arrays multiple times per use --- lib/aws/s3/authentication.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/aws/s3/authentication.rb b/lib/aws/s3/authentication.rb index 895b7f5..4241e0a 100644 --- a/lib/aws/s3/authentication.rb +++ b/lib/aws/s3/authentication.rb @@ -156,6 +156,9 @@ module AWS def query_parameters_for_signature(params) params.select {|k, v| query_parameters.include?(k)} end + memoized :default_headers + memoized :interesting_headers + memoized :query_parameters end attr_reader :request, :headers