enumerations 2.2.0 → 2.2.1

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
  SHA1:
3
- metadata.gz: 7e452f81340fb7e16689b456cab621d4cd84f787
4
- data.tar.gz: 154907cc77af681118cb5639fe0a7e68b3281525
3
+ metadata.gz: 6d3706af5a24b06cfd32e5313ae93aed2d141e1c
4
+ data.tar.gz: 84e6d7f1536f2fda8bf380dfb8aefd93251bf7fe
5
5
  SHA512:
6
- metadata.gz: a8070503f33e094a8344c95a5103cbd71505345efb89ee4d61e5ac84163b0f541cbbc7e1e319a695b1c39eeafd2140b0ef9d4a4895db27bf69cf7cdcb5af1e85
7
- data.tar.gz: a45c4d87770db1b4730094acbfe20abe84cb7f92499b9b42e0eb555e9934d0513353f2ef0670c961c57f867d0d668b2c76369d122de05e6710e5fe521107142f
6
+ metadata.gz: a33613627715d0897356efcef395ba8a9aaaa037a09c10164304c4fa852521c41f11d650cb3d99caa11e96ee41849c750e490fa154516177b23d231d93d61886
7
+ data.tar.gz: 8c79d5499ace432b42be7ba39a0ddac3a425dd23fd1c7da6401340bc6571e0bb13c8a673c4a1899ad98857ab861318753ed9ae9f8b747b7f4c0fc42aa17aaf50
data/enumerations.gemspec CHANGED
@@ -3,7 +3,7 @@ require File.expand_path('../lib/enumerations/version', __FILE__)
3
3
  Gem::Specification.new do |s|
4
4
  s.name = 'enumerations'
5
5
  s.version = Enumerations::VERSION
6
- s.date = '2016-09-15'
6
+ s.date = '2016-09-20'
7
7
  s.summary = 'Enumerations for ActiveRecord!'
8
8
  s.description = 'Extends ActiveRecord with enumeration capabilites.'
9
9
  s.homepage = 'https://github.com/infinum/enumerations'
@@ -1,16 +1,14 @@
1
1
  module Enumerations
2
- class << self
3
- attr_accessor :configuration
2
+ def self.configuration
3
+ @configuration ||= Configuration.new
4
4
  end
5
5
 
6
6
  def self.configure
7
- self.configuration ||= Configuration.new
8
7
  yield(configuration)
9
8
  end
10
9
 
11
10
  def self.restore_default_configuration
12
- self.configuration = nil
13
- configure {}
11
+ @configuration = nil
14
12
  end
15
13
 
16
14
  class Configuration
@@ -1,3 +1,3 @@
1
1
  module Enumerations
2
- VERSION = '2.2.0'.freeze
2
+ VERSION = '2.2.1'.freeze
3
3
  end
@@ -9,8 +9,6 @@ require 'pry'
9
9
  require_relative 'database_helper'
10
10
  require_relative 'locale_helper'
11
11
 
12
- Enumerations.configure { |_| }
13
-
14
12
  class Status < Enumerations::Base
15
13
  values draft: { id: 1, name: 'Draft' },
16
14
  review_pending: { id: 2, name: 'Review pending' },
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: enumerations
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.0
4
+ version: 2.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tomislav Car
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2016-09-15 00:00:00.000000000 Z
15
+ date: 2016-09-20 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: activerecord