title: Fields of hstore emptying if validation fail
body: <p>
  Rails 4.2
  PostgreSQL 9.3.7</p>
  
  <p>I'm using <code>hstore</code> to store some data in key-value format.</p>
  
  <pre class="lang-ruby prettyprint-override"><code>create_table "lang", force: :cascade do |t|
    t.string   "name"
    t.hstore   "dictionary"
    t.datetime "created_at", null: false
    t.datetime "updated_at", null: false
  end
  </code></pre>
  
  <p>In the model I use some validations via store_accessor</p>
  
  <pre class="lang-ruby prettyprint-override"><code>store_accessor :dictionary, :foo, :bar
  validates_presence_of :foo, :bar
  </code></pre>
  
  <p>Part of <code>new</code> action view in <code>slim</code> format:</p>
  
  <pre class="lang-ruby prettyprint-override"><code>= form_for(@lang) do |f|
    .field
      = f.label :name
      = f.text_field :name
    .field
      = f.fields_for :dictionary do |dic_form|
        fieldset
          = dic_form.label :foo
          = dic_form.text_field :foo
          br
          = dic_form.label :bar
          = dic_form.text_field :bar
    .actions = f.submit
  </code></pre>
  
  <p>Why when validation check fails all data I typed in inputs are emptied?
  Eg: I typed only <code>test</code> text in <code>foo</code> field, submit form. See error explanation but <code>test</code> text are disappeared from <code>foo</code> field.</p>
  
  <p>Is there any way to make data persist between requests like in normal rails forms?</p>