has_media 0.2.3 → 0.2.4

Sign up to get free protection for your applications and to get access to all the features.
data/README.rdoc CHANGED
@@ -109,7 +109,7 @@ file : app/models/my_media.rb
109
109
  after_save :enqueue_encoding
110
110
 
111
111
  def enqueue_encoding
112
- Resque.enqueue(EncodeMyMedia, File.join(Rails.root, self.original_file_path))
112
+ Resque.enqueue(EncodeMyMedia, self.original_file_path)
113
113
  end
114
114
  end
115
115
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.3
1
+ 0.2.4
data/has_media.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{has_media}
8
- s.version = "0.2.3"
8
+ s.version = "0.2.4"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["klacointe", "spk"]
@@ -1,5 +1,5 @@
1
- # Set the directory path to use to store media in public folder
2
- HasMedia.directory_path = "media"
1
+ # Set the absolute directory path to use to store media
2
+ HasMedia.directory_path = Rails.root + "media"
3
3
 
4
4
  # Set the base uri to access media
5
5
  HasMedia.directory_uri = "/media"
@@ -13,7 +13,7 @@ class MediumUploader < CarrierWave::Uploader::Base
13
13
 
14
14
  # see https://gist.github.com/519484
15
15
  def root
16
- Rails.root
16
+ HasMedia.directory_path
17
17
  end
18
18
 
19
19
  end
@@ -23,7 +23,7 @@ end
23
23
  describe "HasMedia" do
24
24
 
25
25
  before :all do
26
- HasMedia.directory_path = 'tmp'
26
+ HasMedia.directory_path = '/tmp'
27
27
  HasMedia.directory_uri = '/media'
28
28
  HasMedia.medium_types = {
29
29
  "Image" => ["image/jpeg"],
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: has_media
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 31
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 3
10
- version: 0.2.3
9
+ - 4
10
+ version: 0.2.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - klacointe