mingo 0.4.3 → 0.4.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/mingo/connection.rb +2 -1
  3. metadata +15 -14
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 2463c395e95c4c6a4cc6576e965bc0de69275cca
4
+ data.tar.gz: fea3e272904915b56f4cfb3accb0ee4cdf6c58fc
5
+ SHA512:
6
+ metadata.gz: ea331682889101a6c81969dd1fc59eda16817c9eea9fe08a169b49b0bb4e20b915ae31ea1a18212fc72e9f86bbe110b57db88be7342777ab582b669955c44f66
7
+ data.tar.gz: 71b6e51308ccafbc79b0725d6eef065058a52d9d12e27212c46096f74d691062a6c66e0fffd679f4d49e7f29959a0ebc7817a83b26f8cf73798d328f88a822a0
@@ -14,7 +14,8 @@ class Mingo
14
14
  self.collection = nil
15
15
  self.db = if dbname_or_uri.index('mongodb://') == 0
16
16
  connection = Mongo::Connection.from_uri(dbname_or_uri, options)
17
- connection.db(connection.auths.last['db_name'])
17
+ auth = connection.auths.first
18
+ connection.db(auth.fetch(:db_name) { auth.fetch("db_name") })
18
19
  else
19
20
  Mongo::Connection.new(nil, nil, options).db(dbname_or_uri)
20
21
  end
metadata CHANGED
@@ -1,27 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mingo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
5
- prerelease:
4
+ version: 0.4.4
6
5
  platform: ruby
7
6
  authors:
8
7
  - Mislav Marohnić
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-01-29 00:00:00.000000000 Z
11
+ date: 2015-10-15 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: mongo
16
- requirement: &70278114958640 !ruby/object:Gem::Requirement
17
- none: false
15
+ requirement: !ruby/object:Gem::Requirement
18
16
  requirements:
19
- - - ! '>='
17
+ - - ">="
20
18
  - !ruby/object:Gem::Version
21
19
  version: '1.3'
22
20
  type: :runtime
23
21
  prerelease: false
24
- version_requirements: *70278114958640
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '1.3'
25
27
  description: Mingo is a minimal document-object mapper for MongoDB.
26
28
  email: mislav.marohnic@gmail.com
27
29
  executables: []
@@ -29,6 +31,7 @@ extensions: []
29
31
  extra_rdoc_files: []
30
32
  files:
31
33
  - Rakefile
34
+ - lib/mingo.rb
32
35
  - lib/mingo/callbacks.rb
33
36
  - lib/mingo/changes.rb
34
37
  - lib/mingo/connection.rb
@@ -38,31 +41,29 @@ files:
38
41
  - lib/mingo/persistence.rb
39
42
  - lib/mingo/properties.rb
40
43
  - lib/mingo/timestamps.rb
41
- - lib/mingo.rb
42
44
  - spec/mingo_spec.rb
43
45
  homepage: http://github.com/mislav/mingo
44
46
  licenses: []
47
+ metadata: {}
45
48
  post_install_message:
46
49
  rdoc_options: []
47
50
  require_paths:
48
51
  - lib
49
52
  required_ruby_version: !ruby/object:Gem::Requirement
50
- none: false
51
53
  requirements:
52
- - - ! '>='
54
+ - - ">="
53
55
  - !ruby/object:Gem::Version
54
56
  version: '0'
55
57
  required_rubygems_version: !ruby/object:Gem::Requirement
56
- none: false
57
58
  requirements:
58
- - - ! '>='
59
+ - - ">="
59
60
  - !ruby/object:Gem::Version
60
61
  version: '0'
61
62
  requirements: []
62
63
  rubyforge_project:
63
- rubygems_version: 1.8.12
64
+ rubygems_version: 2.4.5
64
65
  signing_key:
65
- specification_version: 3
66
+ specification_version: 4
66
67
  summary: Minimal Mongo
67
68
  test_files: []
68
69
  has_rdoc: