rails_string_enum 0.5.0 → 0.5.2

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: 5a89d7aa241c25ea1f29072f16f75d0fe4a36897
4
- data.tar.gz: de151b0233565f9d35b2f6794660df13c681a25a
3
+ metadata.gz: fd1412a1c0dac183ae69c88086a0ffeb6bbda037
4
+ data.tar.gz: 4752e6e49b181d8834bae7ccad994c40b0549992
5
5
  SHA512:
6
- metadata.gz: 9c85604c44e26365ecdf8742fbb68666529cd20c800864f98eeff60e7741e0425fa5747827a811c89747472ae724815df09f174284a864a9025512e8c911c0fe
7
- data.tar.gz: 542eac4498a6ad9661d996831d295f4736843cbf8c840a0940769fdc1d39d0d9e7720707513be4133b43038f36867fa3713640896764ecc7f4f504e4f0d46c7b
6
+ metadata.gz: 2c798f679a946b0ce24af2059da2dd47dd56dee2cc52be356d4d06eea8af964df1edd6148dc592bcde189c12ffe88911e624a8791ca3d30a2f338317cfd8ae19
7
+ data.tar.gz: e2f2aed68d85a2d95d293d32915801e51378cc97cfbd93b9fe5300f6deabae5542bab68721d71ee6cd18ed5f96956676d3c5e92e72b6e26d4df5167af29bf7f8
data/README.md CHANGED
@@ -99,7 +99,7 @@ Product.only_red # if scopes: true
99
99
  Product.only_reds # if scopes: { pluralize: true }
100
100
  ```
101
101
 
102
- Using constants to any `Class` or `Module`
102
+ #### Using constants to any `Class` or `Module`
103
103
  ```ruby
104
104
  module ValidateStatesFromApi
105
105
 
@@ -109,7 +109,7 @@ module ValidateStatesFromApi
109
109
  end
110
110
  ```
111
111
 
112
- I18n local file example (compatible with https://github.com/zmbacker/enum_help):
112
+ #### I18n local file example (compatible with https://github.com/zmbacker/enum_help):
113
113
 
114
114
  ```yaml
115
115
  # config/locals/ru.yml
@@ -122,7 +122,7 @@ ru:
122
122
  yellow: Желтый
123
123
  ```
124
124
 
125
- Support `simple_form`:
125
+ #### Support `simple_form`:
126
126
  ```erb
127
127
  <%= f.input :color %>
128
128
  ```
@@ -19,6 +19,12 @@ end
19
19
 
20
20
  begin
21
21
  require 'simple_form'
22
- require 'rails_string_enum/simple_form'
22
+
23
+ begin
24
+ require('enum_help')
25
+ rescue LoadError
26
+ require 'rails_string_enum/simple_form'
27
+ end
28
+
23
29
  rescue LoadError
24
30
  end
@@ -1,3 +1,3 @@
1
1
  module RailsStringEnum
2
- VERSION = "0.5.0"
2
+ VERSION = "0.5.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_string_enum
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - ermolaev
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-03-23 00:00:00.000000000 Z
11
+ date: 2016-04-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler