active_report 5.2.7 → 5.3.0

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: 8bde1de5a7f2f2eea8844b30fd811eb3bde0026344bd5c83386995ac0f40d6a8
4
- data.tar.gz: 0624ceb3f8ded798a662f235eab1050c26ad4fab3ceac2e01d19f44dbdcf2cab
3
+ metadata.gz: aa591c80814598144dc64a86fe3168369038759d2059796c317091f90eaa025f
4
+ data.tar.gz: 89d30d2fd8ed47c6c5d326187eef44aad22227d03f7ae154e93e3494fd9ce098
5
5
  SHA512:
6
- metadata.gz: a314a3fd29f83176b240c40c4a0f9c246c34d849e67dd557a3bec6d33d715377b1ed9a5f59b104b4cf5edbc031c76128d43e1207908995d154a9f5e224302c3f
7
- data.tar.gz: 2799ed6b5c9e652f9a17b491cbacf1a8f132de1672017cbf120372eed28d799c9333a896e695b591e2174f4d38a0ad8e0255169442572fb334cf81d775f35acf
6
+ metadata.gz: ee525e18301da1471931e91fd6eb6c2b0115d943025e05a619684b44e195856f7b2c21db1be556e53589ddee25ec3751797e0adcaee27d6f84f80b3d4ded8358
7
+ data.tar.gz: 60960d818f9850fbb00bf91caa86fa877e7d4f89ceaae12a5ddffa0ab819f54c3d7f52107efc2bebff523be34f5e3b73edfe7194fc6486ee14cd630256ab42ea
@@ -0,0 +1,43 @@
1
+ ---
2
+ detectors:
3
+ Attribute:
4
+ enabled: false
5
+ BooleanParameter:
6
+ enabled: false
7
+ ClassVariable:
8
+ enabled: false
9
+ DuplicateMethodCall:
10
+ enabled: false
11
+ FeatureEnvy:
12
+ enabled: false
13
+ IrresponsibleModule:
14
+ enabled: false
15
+ InstanceVariableAssumption:
16
+ enabled: false
17
+ LongParameterList:
18
+ enabled: false
19
+ ManualDispatch:
20
+ enabled: false
21
+ NestedIterators:
22
+ max_allowed_nesting: 2
23
+ NilCheck:
24
+ enabled: false
25
+ TooManyInstanceVariables:
26
+ enabled: false
27
+ TooManyMethods:
28
+ enabled: false
29
+ TooManyStatements:
30
+ max_statements: 10
31
+ exclude:
32
+ - 'ActiveReport::Base#metamorph'
33
+ - 'ActiveReport::Hash#import'
34
+ - 'ActiveReport::Record#export'
35
+ - 'ActiveReport::Record#import'
36
+ UncommunicativeMethodName:
37
+ exclude:
38
+ - 'ActiveReport::Base#encode_to_utf8'
39
+ UncommunicativeVariableName:
40
+ exclude:
41
+ - 'ActiveReport::Hash#import'
42
+ UtilityFunction:
43
+ enabled: false
@@ -47,16 +47,19 @@ class ActiveReport::Base
47
47
 
48
48
  def active_record_table_object?(object)
49
49
  return if object.nil?
50
+
50
51
  !object.respond_to?(:table_name)
51
52
  end
52
53
 
53
54
  def active_record_table_class?(object)
54
55
  return if object.nil? || object.is_a?(ActiveRecord::Relation)
56
+
55
57
  object.respond_to?(:table_name) || object.is_a?(Ransack::Search)
56
58
  end
57
59
 
58
60
  def active_record_column_names(object)
59
61
  return object.klass.column_names if object.is_a?(Ransack::Search)
62
+
60
63
  object.column_names
61
64
  end
62
65
 
@@ -131,6 +134,7 @@ class ActiveReport::Base
131
134
 
132
135
  def metatransform(data)
133
136
  return if data.empty?
137
+
134
138
  evaluate? ? metamorph(data) : data
135
139
  end
136
140
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveReport
4
- VERSION ||= '5.2.7'
4
+ VERSION ||= '5.3.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_report
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.2.7
4
+ version: 5.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Gomez
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-05-24 00:00:00.000000000 Z
11
+ date: 2018-09-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -176,7 +176,7 @@ files:
176
176
  - ".coveralls.yml"
177
177
  - ".fasterer.yml"
178
178
  - ".gitignore"
179
- - ".reek"
179
+ - ".reek.yml"
180
180
  - ".rspec"
181
181
  - ".rubocop.yml"
182
182
  - ".travis.yml"
@@ -218,7 +218,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
218
218
  version: '0'
219
219
  requirements: []
220
220
  rubyforge_project:
221
- rubygems_version: 2.7.6
221
+ rubygems_version: 2.7.7
222
222
  signing_key:
223
223
  specification_version: 4
224
224
  summary: Gem for exporting/importing ruby objects to flat files vice versa.
data/.reek DELETED
@@ -1,42 +0,0 @@
1
- ---
2
- Attribute:
3
- enabled: false
4
- BooleanParameter:
5
- enabled: false
6
- ClassVariable:
7
- enabled: false
8
- DuplicateMethodCall:
9
- enabled: false
10
- FeatureEnvy:
11
- enabled: false
12
- IrresponsibleModule:
13
- enabled: false
14
- InstanceVariableAssumption:
15
- enabled: false
16
- LongParameterList:
17
- enabled: false
18
- ManualDispatch:
19
- enabled: false
20
- NestedIterators:
21
- max_allowed_nesting: 2
22
- NilCheck:
23
- enabled: false
24
- TooManyInstanceVariables:
25
- enabled: false
26
- TooManyMethods:
27
- enabled: false
28
- TooManyStatements:
29
- max_statements: 10
30
- exclude:
31
- - 'ActiveReport::Base#metamorph'
32
- - 'ActiveReport::Hash#import'
33
- - 'ActiveReport::Record#export'
34
- - 'ActiveReport::Record#import'
35
- UncommunicativeMethodName:
36
- exclude:
37
- - 'ActiveReport::Base#encode_to_utf8'
38
- UncommunicativeVariableName:
39
- exclude:
40
- - 'ActiveReport::Hash#import'
41
- UtilityFunction:
42
- enabled: false