lazy_blob_storage 2.0.0.pre.beta.1 → 2.0.0.pre.beta.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2f76aadde1c8e491a20d9d43ab01b4726ba9039f4a50b0aa60cbcc571493939f
4
- data.tar.gz: 0f38de7c7d200daa0208fe363a4ce8a6d7d175121fd1aef55563022e8fe3102b
3
+ metadata.gz: c675223c056ffa300a4910dea9ff45c01ea77c8115d673e530105dc85e7fdc4e
4
+ data.tar.gz: 54b144adb7025c08c862333874cb2943f84177020fa4b5965003232c8353bb27
5
5
  SHA512:
6
- metadata.gz: 0c37f509e254d0494c019dd60510d07d8ad023ad22d6b3413475424afd82ba60ce138019b0526ca7dcee6908d822dea3b95417d8d490710a0a81a0518558b30c
7
- data.tar.gz: d1a8b8c8cf70dd6c8d9e4a7cb634781821908ac08e89a54d46fdc9bd98ec40fa8c1910f9ed8dafad6fdee84cd6fdaece89c187afc73767d453f1586d4710623d
6
+ metadata.gz: a88c198067cdf6ec766b975ee96c3c22553c7b6832491db51cc681d616b9b735abfc1dd02c151a5141bc22ac905a2cdb51fd343f6869328f9179fb2f720e1e6f
7
+ data.tar.gz: 261c7c6e70daa001281b284edd136ea5551f55ac50173c5ab5c0bd3c471ca192ebf3e4db2c73a55474c49cfa1e1c5adc7b499b93db46902eced3d94b7d7fe2c4
data/README.md CHANGED
@@ -37,7 +37,7 @@ Built with Rails 6. It could ~probably~ work with Rails 4/5, too.
37
37
  ## Usage
38
38
 
39
39
  1. Add `gem "lazy_blob_storage" to Gemfile`
40
- 1. Run `rake lazy_blob_storage:install:migrations`
40
+ 1. Run `rake lazy_blob_storage_engine:install:migrations`
41
41
  1. Run `rake db:migrate`
42
42
  1. Declare `has_lazy_attached :image` in some model
43
43
  1. Add `f.file_field :image_upload` to the form template
@@ -26,7 +26,7 @@ module LazyAttachable
26
26
 
27
27
  define_method("validate_size_of_#{name}_upload") do
28
28
  if (send "#{name}_upload").present? && !(send "#{name}_upload_size_ok?")
29
- errors.add("#{name}_upload", "file too large (limit 1 MB)")
29
+ errors.add("#{name}_upload", "file too large (limit #{(LazyBlobStorage.max_blob_size || LazyBlobStorage.default_max_blob_size) / 1_000} kb")
30
30
  end
31
31
  end
32
32
 
@@ -1,3 +1,3 @@
1
1
  module LazyBlobStorage
2
- VERSION = "2.0.0-beta.1"
2
+ VERSION = "2.0.0-beta.3"
3
3
  end
@@ -1,7 +1,4 @@
1
1
  namespace :lazy_blob_storage do
2
- # Prevent migration installation task from showing up twice.
3
- Rake::Task["install:migrations"].clear_comments
4
-
5
2
  desc "Copy over the migration needed to the application"
6
3
  task install: :environment do
7
4
  if Rake::Task.task_defined?("lazy_blob_storage:install:migrations")
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lazy_blob_storage
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0.pre.beta.1
4
+ version: 2.0.0.pre.beta.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Corey Smedstad