Nice

On Thu, Mar 20, 2014 at 12:01 PM, Ash Wilson <notifications@github.com>
wrote:

>> @@ -55,9 +55,16 @@ def create_temp_url(container, object, expires, method, options = {})
>>            hmac = Fog::HMAC.new('sha1', @openstack_temp_url_key)
>>            sig  = sig_to_hex(hmac.sign(string_to_sign))
>>  
>> -          "#{scheme}://#{@host}#{object_path_escaped}?temp_url_sig=#{sig}&temp_url_expires=#{expires}"
>> +          port = ''
>> +          case scheme
>> +          when 'http' then port = ":#{@port}" unless @port == 80
>> +          when 'https' then port = ":#{@port}" unless @port == 443
>> +          else port = ":#{@port}"
>> +          end
> @tokengeek :+1: for using `URI`. That's much better and handles all of the edge cases so we don't have to.
> ---
> Reply to this email directly or view it on GitHub:
> https://github.com/fog/fog/pull/2781/files#r10801508