tramway-admin 1.7.7.1 → 1.7.8

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: 313f7fccd039bd897467fd55e7e56fe9890e6b18842ab37a2a6102c85cf4b9aa
4
- data.tar.gz: b9e4a87d5cbcd2ff742b582ccf9f4cbcfd3dd80cdead816c95cfd0834e8b8e26
3
+ metadata.gz: 3853d33fef58959a023f924776a7d0c9ec2bcab93f7af0403b19313689591436
4
+ data.tar.gz: 78e1f5e5ae3eb6bf274ae0011a04d17e371aebf8419e6f2d26c888b99c50a93b
5
5
  SHA512:
6
- metadata.gz: 990beabf0e608fcfeee5a8d5c401553d5ef13ff3c5f19aca395cc50bba06a03a035fa410a41f0c1c60b2d582db22a64077ae554e6beb47daa0d46541e5189935
7
- data.tar.gz: abaf784d338610ad564a86946b9e289e9e7c6c823d0e0136858370929688c47a664047018ccc723df62ee389007cc43ec23a3a40669f10abc8e50992e2973970
6
+ metadata.gz: 5a0479daa4c17c851755b71b07411287072418d49b64d127b4a48066ccae944e5d565235809ccaeaa028f0aa8cdabd7378e45499fb389f7645eedd9c8950b8cb
7
+ data.tar.gz: 0b7278023197415bea97b0845c4935ec1fe70d4253fd9e66ec4b8272f3022d9173fa7593a63149553c82368b080e41031df0ba3d6c515ca486e9450322786e69
@@ -28,7 +28,12 @@ module Tramway
28
28
  end
29
29
 
30
30
  def available_models
31
- @available_models.values.flatten
31
+ if @available_models
32
+ @available_models.values.flatten
33
+ else
34
+ error = Tramway::Error.new(plugin: :admin, method: :available_models, message: ('List of available_models is empty. You should add some of them using `::Tramway::Admin.set_available_models(*list_of_classes, project: :your_project_name)` in `config/initializers/tramway.rb`'))
35
+ raise error.message
36
+ end
32
37
  end
33
38
 
34
39
  def set_singleton_models(*models, project:)
@@ -1,5 +1,5 @@
1
1
  module Tramway
2
2
  module Admin
3
- VERSION = '1.7.7.1'
3
+ VERSION = '1.7.8'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tramway-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.7.1
4
+ version: 1.7.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pavel Kalashnikov