public
Description: Ruby on Rails
Homepage: http://rubyonrails.org
Clone URL: git://github.com/rails/rails.git
I18n: use :other instead of :many as default key for pluralization to better 
conform w/ cldr pluralization rules

Signed-off-by: Michael Koziarski <michael@koziarski.com>
svenfuchs (author)
Sat Aug 23 10:43:57 -0700 2008
NZKoz (committer)
Sat Aug 23 12:23:00 -0700 2008
commit  d6989aa0e1fe5e49fe1fccc3702aa7ff62a63faf
tree    591897097513ca99f3655fe6b74bdd440f5adb0a
parent  b1f3c6e6ec08a40fc7153ee3ba78d51b466a58e6
...
51
52
53
54
 
55
56
57
 
58
59
60
 
61
62
63
 
64
65
66
 
67
68
69
 
70
71
72
 
73
74
75
 
76
77
78
 
79
80
81
 
82
83
84
85
86
87
88
 
89
90
91
...
51
52
53
 
54
55
56
 
57
58
59
 
60
61
62
 
63
64
65
 
66
67
68
 
69
70
71
 
72
73
74
 
75
76
77
 
78
79
80
 
81
82
83
84
85
86
87
 
88
89
90
91
0
@@ -51,41 +51,41 @@
0
       half_a_minute: "half a minute"
0
       less_than_x_seconds:
0
         one:  "less than 1 second"
0
-        many: "less than {{count}} seconds"
0
+        other: "less than {{count}} seconds"
0
       x_seconds:
0
         one:  "1 second"
0
-        many: "{{count}} seconds"
0
+        other: "{{count}} seconds"
0
       less_than_x_minutes:
0
         one:  "less than a minute"
0
-        many: "less than {{count}} minutes"
0
+        other: "less than {{count}} minutes"
0
       x_minutes:
0
         one:  "1 minute"
0
-        many: "{{count}} minutes"
0
+        other: "{{count}} minutes"
0
       about_x_hours:
0
         one:  "about 1 hour"
0
-        many: "about {{count}} hours"
0
+        other: "about {{count}} hours"
0
       x_days:
0
         one:  "1 day"
0
-        many: "{{count}} days"
0
+        other: "{{count}} days"
0
       about_x_months:
0
         one:  "about 1 month"
0
-        many: "about {{count}} months"
0
+        other: "about {{count}} months"
0
       x_months:
0
         one:  "1 month"
0
-        many: "{{count}} months"
0
+        other: "{{count}} months"
0
       about_x_years:
0
         one:  "about 1 year"
0
-        many: "about {{count}} years"
0
+        other: "about {{count}} years"
0
       over_x_years:
0
         one:  "over 1 year"
0
-        many: "over {{count}} years"
0
+        other: "over {{count}} years"
0
 
0
   activerecord:
0
     errors:
0
       template:
0
         header:
0
           one:   "1 error prohibited this {{model}} from being saved"
0
-          many:  "{{count}} errors prohibited this {{model}} from being saved"
0
+          other:  "{{count}} errors prohibited this {{model}} from being saved"
0
         # The variable :count is also available
0
         body: "There were problems with the following fields:"
0
 
...
104
105
106
107
 
108
109
110
...
104
105
106
 
107
108
109
110
0
@@ -104,7 +104,7 @@ module I18n
0
           return entry unless entry.is_a?(Hash) and count
0
           # raise InvalidPluralizationData.new(entry, count) unless entry.is_a?(Hash)
0
           key = :zero if count == 0 && entry.has_key?(:zero)
0
-          key ||= count == 1 ? :one : :many
0
+          key ||= count == 1 ? :one : :other
0
           raise InvalidPluralizationData.new(entry, count) unless entry.has_key?(key)
0
           entry[key]
0
         end

Comments