common_validators 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -22,7 +22,7 @@ In your ActiveRecord models include one more validations on your model's fields.
22
22
 
23
23
  Add this line to your application's Gemfile:
24
24
 
25
- gem 'venture_base'
25
+ gem 'common_validators'
26
26
 
27
27
  And then execute:
28
28
 
@@ -30,7 +30,7 @@ And then execute:
30
30
 
31
31
  Or install it yourself as:
32
32
 
33
- $ gem install venture_base
33
+ $ gem install common_validators
34
34
 
35
35
  ## Contributing
36
36
 
@@ -38,7 +38,7 @@ class MoneyFormatValidator < ActiveModel::EachValidator
38
38
 
39
39
  # Check if value has cents but shouldn't
40
40
  if options[:exclude_cents] && value_has_cents?(value)
41
- record.errors.add(attr_name, :money_format_whole_number)
41
+ record.errors.add(attr_name, :money_format_has_cents)
42
42
  end
43
43
  end
44
44
 
@@ -4,6 +4,6 @@ en:
4
4
  date_format: "is invalid"
5
5
  email_format: "is invalid"
6
6
  money_format: "is invalid"
7
- money_format_whole_dollar: "must be whole dollar amount"
7
+ money_format_has_cents: "must not include cents"
8
8
  slug_format: "is invalid, only lowercase letters and numbers allowed"
9
9
  url_format: "is invalid"
@@ -1,3 +1,3 @@
1
1
  module CommonValidators
2
- VERSION = "1.0.1"
2
+ VERSION = "1.0.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: common_validators
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-07-24 00:00:00.000000000 Z
12
+ date: 2013-08-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -161,7 +161,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
161
161
  version: '0'
162
162
  segments:
163
163
  - 0
164
- hash: -922536056553976169
164
+ hash: 3801570283070740379
165
165
  requirements: []
166
166
  rubyforge_project:
167
167
  rubygems_version: 1.8.23