fanforce-internal-validations 0.1.5 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/lib/fanforce/validations/validations.rb +1 -1
- data/lib/fanforce/validations/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
YzM4MjJjN2I2ODI0OWYzMmY3YzZkZjlhOTljM2RjMGVjZjAxZDc0Yw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZjVhYThjMTU4ZDM4MzI5ZDg5ZTAyMmUwYmE4ZjAzZTg4YjFjNzVlNA==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
MTg5MjA3Yjc3YzQ1NmI4NGM0N2FiMjljZGMzN2IwZjY5YTY0MmE0NzI2NDky
|
10
|
+
YzkwMGYwY2RiM2IxZDVkMzNjMTBkMDljMzAxMTk3M2YwNDBiMDBmYWI2MWJi
|
11
|
+
MGQwOGUzNTIyODMzOTk2MjEwNTUxNGE2MTBhMDZhOTFiYzEwMTg=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZGJmMmFkMzBjNDQ1NmJjNGNhZGE1NGE5ODVkZWM5YWU3ZjZiNmRmYzQwZTQ2
|
14
|
+
NzYwZjEzMjQyZTE1MzFjNzhjZTIyODMyMTBiNzdiNWQyOWQ2NmEwZWY5Zjdm
|
15
|
+
NGZjNzk4MzMxNzY4N2E2YTBkOGNjNDE1YzljMTczYWQ1NjE2OWI=
|
@@ -75,7 +75,7 @@ module Fanforce::Validations
|
|
75
75
|
|
76
76
|
def format_validation_error(opts, fields, default_error_code=nil)
|
77
77
|
error = {
|
78
|
-
resource: is_present?(opts[:resource]) ? opts[:resource] : self.class.name.demodulize.tableize.singularize,
|
78
|
+
resource: is_present?(opts[:resource]) ? opts[:resource] : (self.class==Class ? self.name.demodulize.tableize.singularize : self.class.name.demodulize.tableize.singularize),
|
79
79
|
code: is_present?(opts[:code]) ? opts[:code] : default_error_code,
|
80
80
|
message: opts[:message]
|
81
81
|
}
|