model_attachment 0.0.11 → 0.0.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. data/lib/model_attachment.rb +3 -6
  2. metadata +3 -3
@@ -14,7 +14,7 @@ require 'model_attachment/amazon'
14
14
 
15
15
  # The base module that gets included in ActiveRecord::Base.
16
16
  module ModelAttachment
17
- VERSION = "0.0.11"
17
+ VERSION = "0.0.12"
18
18
 
19
19
  class << self
20
20
 
@@ -127,12 +127,9 @@ module ModelAttachment
127
127
  proto = options[:proto] || "http"
128
128
  port = options[:port]
129
129
  server_name = options[:server_name] || "localhost"
130
- url_path = options[:path] || "/#{self.class.to_s.downcase.pluralize}/deliver/"
130
+ url_path = options[:path] || "/#{self.class.to_s.downcase.pluralize}/"
131
131
  type = options[:type]
132
132
 
133
- version = options[:version]
134
- version_string = "?v=#{version}" if version
135
-
136
133
  server_name += ":" + port.to_s if port
137
134
  type_string = "?type=#{type}" if type
138
135
 
@@ -148,7 +145,7 @@ module ModelAttachment
148
145
  url = "#{proto}://#{server_name}#{url_path}#{basename}#{type_string}#{extension}"
149
146
  elsif bucket.nil?
150
147
  # otherwise use private url with deliver
151
- url = "#{proto}://#{server_name}#{url_path}#{id}#{type_string}#{version_string}"
148
+ url = "#{proto}://#{server_name}#{url_path}#{id}#{type_string}"
152
149
  else
153
150
  # if bucket is set, then use aws url
154
151
  url = aws_url(type)
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 0
8
- - 11
9
- version: 0.0.11
8
+ - 12
9
+ version: 0.0.12
10
10
  platform: ruby
11
11
  authors:
12
12
  - Steve Walker
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-05-18 00:00:00 -04:00
17
+ date: 2010-06-02 00:00:00 -04:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency