jko_api 0.2.7.0 → 0.2.9

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
- SHA1:
3
- metadata.gz: def5a6888ceec83c82b7d42705feeb901978bfe6
4
- data.tar.gz: 296866d4aaf9b5b08e6f819c9e7f1c23a57ec64d
2
+ SHA256:
3
+ metadata.gz: 88aaa8b5e8d2dbda590b75a03aa6a860f982fe2be6bab9b2cd85ccc2a7e1b579
4
+ data.tar.gz: d3a107e9504ab41724cee758bb4f987f0c47de5b8f04a1a29943a4c1b79f1dd5
5
5
  SHA512:
6
- metadata.gz: 275184031ebb07f89eb0d75385ed586d666d2da619a02aadcfe589568791c64d63d737e78101032bb1e34899b29d624cff3d22ab377abc81a95d425136467a2f
7
- data.tar.gz: 3a63fae9e3a2e2a9d6e626991ee0df9bcbcc116a41afdced4833befda7c48ed5436b3aa43875d44e6a7e0135ea86dc07cb3e33f56b73430cda733a9436d8a9cf
6
+ metadata.gz: fd91bf624a79ba36727c6ff46964b785aa250d2704958a54946e2a777a70f2317a24f4730a2de0f87df2cdd68f2633db5a0208488a7c0996c959b4e43e0fbdfd
7
+ data.tar.gz: f2426c6e85c5febd3abcc5317f324f97b790ad8bed546d57bec5051ebef4e286968334821365732788c0cdd16401e95a4c2df1af8d862a4c9d93bb3d1c07b00b
@@ -18,9 +18,9 @@ Gem::Specification.new do |spec|
18
18
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
19
  spec.require_paths = ["lib"]
20
20
 
21
- spec.add_development_dependency "bundler", ">= 1.7"
22
- spec.add_development_dependency "rake", ">= 10.0"
23
- spec.add_dependency "responders", "2.4.0"
24
- spec.add_dependency "rails", ">= 4.2.7", "<= 5.1.4"
21
+ spec.add_development_dependency "bundler"
22
+ spec.add_development_dependency "rake"
23
+ spec.add_dependency "responders", ">= 2.4.0"
24
+ spec.add_dependency "rails", ">= 4.2.7"
25
25
  spec.add_dependency "warden-oauth2"
26
26
  end
@@ -24,15 +24,18 @@ module JkoApi
24
24
  mattr_accessor :configuration, instance_accessor: false
25
25
  mattr_accessor :auth_initializer, instance_accessor: false
26
26
  mattr_reader :current_version_number, instance_reader: false
27
+ @@versioning = nil
27
28
 
28
29
  def self.configure
29
30
  self.configuration ||= Configuration.new
30
31
  yield(configuration)
31
- setup(configuration.base_controller)
32
+ self.configuration
32
33
  end
33
34
 
34
- def self.setup(base_controller)
35
- Util.stupid_hack!
35
+ def self.complete_setup(base_controller)
36
+ if Rails.version.to_i < 5
37
+ Util.stupid_hack!
38
+ end
36
39
  ClassDescendantsBuilder.build(base_controller, upto: max_version_number)
37
40
  @@auth_initializer.call
38
41
  end
@@ -69,6 +72,8 @@ module JkoApi
69
72
  context.scope(module: JkoApi.configuration.api_namespace, constraints: JkoApi::Constraints, defaults: {format: :json}) do
70
73
  JkoApi.versions(context, &block)
71
74
  end
75
+ complete_setup(configuration.base_controller)
76
+ context
72
77
  end
73
78
 
74
79
  def self.auth_setup(&block)
@@ -1,6 +1,8 @@
1
1
  module JkoApi
2
2
  class Util
3
3
 
4
+ # This was a hack needed in rails 4.2
5
+ # I'm keeping the code for backwards compatibility (for now)
4
6
  def self.stupid_hack!
5
7
  Rails.application.reload_routes!
6
8
  eager_load_api_controllers
@@ -1,3 +1,3 @@
1
1
  module JkoApi
2
- VERSION = "0.2.7.0"
2
+ VERSION = "0.2.9"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jko_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.7.0
4
+ version: 0.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Woertink
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-03-26 00:00:00.000000000 Z
11
+ date: 2020-08-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,40 +16,40 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '1.7'
19
+ version: '0'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '1.7'
26
+ version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
33
+ version: '0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: '0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: responders
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '='
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
47
  version: 2.4.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '='
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: 2.4.0
55
55
  - !ruby/object:Gem::Dependency
@@ -59,9 +59,6 @@ dependencies:
59
59
  - - ">="
60
60
  - !ruby/object:Gem::Version
61
61
  version: 4.2.7
62
- - - "<="
63
- - !ruby/object:Gem::Version
64
- version: 5.1.4
65
62
  type: :runtime
66
63
  prerelease: false
67
64
  version_requirements: !ruby/object:Gem::Requirement
@@ -69,9 +66,6 @@ dependencies:
69
66
  - - ">="
70
67
  - !ruby/object:Gem::Version
71
68
  version: 4.2.7
72
- - - "<="
73
- - !ruby/object:Gem::Version
74
- version: 5.1.4
75
69
  - !ruby/object:Gem::Dependency
76
70
  name: warden-oauth2
77
71
  requirement: !ruby/object:Gem::Requirement
@@ -137,8 +131,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
137
131
  - !ruby/object:Gem::Version
138
132
  version: '0'
139
133
  requirements: []
140
- rubyforge_project:
141
- rubygems_version: 2.6.11
134
+ rubygems_version: 3.1.2
142
135
  signing_key:
143
136
  specification_version: 4
144
137
  summary: A Rails API gem