Paulo Tarud
Paulo Tarud
When a cached resource is trying to fetch it has_many associations it crashed. from /home/ptarud/.rvm/gems/ruby-2.4.0/gems/cached_resource-5.0.1/lib/cached_resource/caching.rb:91:in `new' from /home/ptarud/.rvm/gems/ruby-2.4.0/gems/cached_resource-5.0.1/lib/cached_resource/caching.rb:91:in `block in cache_read' from /home/ptarud/.rvm/gems/ruby-2.4.0/gems/activesupport-5.2.0/lib/active_support/core_ext/object/try.rb:16:in `try!' from /home/ptarud/.rvm/gems/ruby-2.4.0/gems/activesupport-5.2.0/lib/active_support/core_ext/object/try.rb:8:in `try' from /home/ptarud/.rvm/gems/ruby-2.4.0/gems/cached_resource-5.0.1/lib/cached_resource/caching.rb:87:in `cache_read'...
It seems jbuilder make SQL query before render it jbuilder. Is not using ActiveRecord::Associations passed from controller correctly. Example: ```ruby # Model class Product has_many :product_sides has_many :product_side_images, through: :product_sides...
has_many relationships are not correctly sorted by id ascending as they should be, that cause the user should specify in the relationship the order. This is not a common behaviour...
Add a tenantable_belongs_to class method that automatically validates that the parent association must has the same tenant than the record is defining the tenantable_belongs_to association.