thecore_api 1.5.5 → 1.5.7

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4b0182daacbd83f547c605d97132c47a51c88891563d962a9ff2cad9d62ffa06
4
- data.tar.gz: 472775a07973cc618d1c5806884b9f5cf42e9852fcd19b27e7253f7da641baab
3
+ metadata.gz: 9c0a58fe7f76f77865720c5cb5b9fff3bfcca8060fb793f63bdfbce3d3a9ef13
4
+ data.tar.gz: e9460f642937700436d91b81dd1d66d15d45d9969e54584d341aa88262e57c0e
5
5
  SHA512:
6
- metadata.gz: 5713ce668a8bc8431cd3e54a7874811c24eb24bd55844df19400abccddab210b10436afe5d260a6195cf178fd7ebd893f58a37daea06a29cc0d45a87b6d379cd
7
- data.tar.gz: 9f1cc1e044d6831827cea4eabccb27a891429c3311c3ebf4fd01989df95d6d0655b634444f75122d599619f6982980cd4c5b3a6e86339d13d26c3251f3c9023b
6
+ metadata.gz: e2304475f581a222012b6b369f83aeea39023487159045312b6253bee5b4696f11fc72c25bf294564feb84590edbdd21c69e0f9d36c13f49a55461f8b3e5d0b6
7
+ data.tar.gz: f1d772697e5d8de929d1c1186a0f21fa6e25afae9490045756345008731b63db901c3f480d5cbd426f92a6c288c3b995dbfb6b69a9bc496a54694b07466b7387
@@ -29,8 +29,8 @@ class Api::V1::BaseController < ActionController::API
29
29
  rescue_from ActiveRecord::RecordInvalid, with: :invalid!
30
30
  rescue_from CanCan::AccessDenied, with: :unauthorized!
31
31
  rescue_from ActiveRecord::RecordNotFound, with: :not_found!
32
- rescue_from NameError, with: :name_error!
33
- rescue_from NoMethodError, with: :no_method_error!
32
+ # rescue_from NameError, with: :name_error!
33
+ # rescue_from NoMethodError, with: :no_method_error!
34
34
  # rescue_from ::RubySpark::Device::ApiError, with: :fivehundred!
35
35
 
36
36
  attr_accessor :current_user
@@ -177,7 +177,7 @@ class Api::V1::BaseController < ActionController::API
177
177
  end
178
178
 
179
179
  def update
180
- @record.update_attributes(request_params)
180
+ @record.update_attributes!(request_params)
181
181
 
182
182
  render json: @record.to_json(json_attrs), status: 200
183
183
  end
@@ -53,6 +53,7 @@ class Api::V1::InfoController < Api::V1::BaseController
53
53
  a.name if (((a.options[:class_name].presence || a.name).to_s.classify.constantize.new.is_a? ApplicationRecord) rescue false)
54
54
  }.compact
55
55
  }
56
+ pivot[model][:methods] ||= (d.instance_methods(false).include?(:json_attrs) && !d.json_attrs.blank?) ? d.json_attrs[:methods] : nil
56
57
  end
57
58
  render json: pivot.to_json, status: 200
58
59
  end
@@ -1,3 +1,3 @@
1
1
  module ThecoreApi
2
- VERSION = "1.5.5".freeze
2
+ VERSION = "1.5.7".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thecore_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.5
4
+ version: 1.5.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gabriele Tassoni
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-17 00:00:00.000000000 Z
11
+ date: 2020-01-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thecore
@@ -161,7 +161,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
161
161
  - !ruby/object:Gem::Version
162
162
  version: '0'
163
163
  requirements: []
164
- rubygems_version: 3.0.1
164
+ rubygems_version: 3.0.6
165
165
  signing_key:
166
166
  specification_version: 4
167
167
  summary: Taris API.