grape-activerecord 1.0.2 → 1.0.3

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
  SHA1:
3
- metadata.gz: d7798a801d0b06bc3c6d9d5ce4963607d194055e
4
- data.tar.gz: 80ee2a0e1a22efbbbbcde3f82db262dfad101f4d
3
+ metadata.gz: 277fa119f61a75f2b6920ad1e4b885d23e687fc3
4
+ data.tar.gz: 30829e43950d647ceb2290983c6121948863b9fb
5
5
  SHA512:
6
- metadata.gz: d2c9dd61350a7fcd8f10670929f93ee53a45a01c8ffa728103a9bf75411f6c100a468ce9170a957805806acfa9340b22d833db0cbd5167f49b7e9923adf8673e
7
- data.tar.gz: 8081033ff7aebc1ec079f30841512da5c18c580f0e6252d25affe5b11a896b7d5a00c53a6eb6896021de7291d1593ddb261c25fc01b5ba936d3f49436b4f3fc5
6
+ metadata.gz: 6377dc5c48e482106997bc2a75aa238dac39c09b3a2eebdd5ba85392518742d1eb8accdc5de240585b5daa223ae263f3c9f8f05eaa332d58ddbf1a879fb056a7
7
+ data.tar.gz: 03cada4ffaa98838717c078b1a18d5c30f61d6e66fc0ca5eb8e104413e54f9f466492e37ccc018c15b4be99760884a2810fb7479cc6ad93aaa83de457b9d4f8f
@@ -14,8 +14,7 @@ module Grape
14
14
 
15
15
  # Connect to database with a DB URL. Example: "postgres://user:pass@localhost/db"
16
16
  def self.database_url=(url)
17
- ::ActiveRecord::Base.establish_connection(url)
18
- ::ActiveRecord::Base.configurations = {RACK_ENV.to_s => ::ActiveRecord::Base.connection.pool.spec.config}
17
+ self.database = ::ActiveRecord::ConnectionAdapters::ConnectionSpecification::ConnectionUrlResolver.new(url).to_hash
19
18
  end
20
19
 
21
20
  # Connect to database with a yml file. Example: "config/database.yml"
@@ -1,6 +1,6 @@
1
1
  module Grape
2
2
  module ActiveRecord
3
3
  # Gem version
4
- VERSION = '1.0.2'
4
+ VERSION = '1.0.3'
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: grape-activerecord
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jordan Hollinger
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-08-14 00:00:00.000000000 Z
11
+ date: 2015-08-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: grape
@@ -87,7 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
87
87
  version: '0'
88
88
  requirements: []
89
89
  rubyforge_project:
90
- rubygems_version: 2.4.5
90
+ rubygems_version: 2.4.5.1
91
91
  signing_key:
92
92
  specification_version: 4
93
93
  summary: ActiveRecord integration for Grape