embedded_localization 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.textile CHANGED
@@ -205,6 +205,12 @@ If your requirements are different, my approach might not work for you. In that
205
205
 
206
206
  h2. Changes
207
207
 
208
+ h3. 0.2.2 (2012-02-06)
209
+ * bugfix for attr_writer
210
+
211
+ h3. 0.2.1 (2012-01-31)
212
+ * bugfix for serialized i18n attribute
213
+
208
214
  h3. 0.2.0 (2012-01-31)
209
215
  * added support for having DB columns for translated attributes, to enable SQL queries in I18n.default_locale
210
216
 
@@ -71,6 +71,7 @@ module EmbeddedLocalization
71
71
  if self.attributes.has_key?(attr_name.to_s) # if user has defined DB field with that name
72
72
  write_attribute(attr_name , new_translation) if I18n.locale == I18n.default_locale
73
73
  end
74
+ self.i18n ||= Hash.new
74
75
  self.i18n[I18n.locale] ||= Hash.new
75
76
  self.i18n[I18n.locale][attr_name.to_sym] = new_translation
76
77
  end
@@ -1,3 +1,3 @@
1
1
  module EmbeddedLocalization
2
- VERSION = '0.2.1'
2
+ VERSION = '0.2.2'
3
3
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: embedded_localization
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.2.1
5
+ version: 0.2.2
6
6
  platform: ruby
7
7
  authors:
8
8
  - Tilo Sloboda
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2012-02-01 00:00:00 Z
13
+ date: 2012-02-07 00:00:00 Z
14
14
  dependencies: []
15
15
 
16
16
  description: "Rails I18n: Embedded_Localization for ActiveRecord 3 is very lightweight, and allows you to transparently store translations of attributes right inside each record -- no extra database tables needed to store the localization data!"