title: Why don't my locale settings in number_to_currency work?
body: <p>Per the <a href="https://api.rubyonrails.org/v3.2.16/" rel="noreferrer">Rails 3.2 API Docs</a>, to use different locales for <code>number_to_currency</code>, I need to do the following:</p>
  
  <pre><code>&lt;%= number_to_currency(1234567890.506, :locale =&gt; :fr) %&gt;
  </code></pre>
  
  <p>I was expecting the following output:</p>
  
  <pre><code># =&gt; 1 234 567 890,51 €
  </code></pre>
  
  <p>Even though I literally use that exact thing within my app and it keeps outputting the following:</p>
  
  <pre><code>$1,234,567,890.51
  </code></pre>
  
  <p>When I check for the <code>available_locales</code> within my app I get the following:</p>
  
  <pre><code>&gt; I18n.available_locales
  =&gt; [:en, :de, :es, :fr, :ja, :pl, :"pt-BR", :ru, :sv, :"zh-CN"]
  </code></pre>
  
  <p>So it SHOULD work, but it doesn't.</p>
  
  <p>What am I missing?</p>
  
  <p><strong>Update 1</strong></p>
  
  <p>Per @s3tjan's comment, I did some digging in that linked Rails issue and that led me to my <code>application.rb</code> where I discovered <code>I18n.enforce_available_locales = false</code>. I changed that to true and restarted the server.</p>
  
  <p>When I tried the above again, I am now getting this error:</p>
  
  <pre><code>ActionView::Template::Error (:fr is not a valid locale):
  </code></pre>
  
  <p>Not sure how to fix this.</p>
  
  <p><strong>Update 2</strong></p>
  
  <p>So I just realize that I never had a locale file in my <code>config/locales</code>. What I really want is to use the GBP Pounds for currency, so I added an <code>en-GB.yml</code> file in my <code>config/locales</code>, then I restarted my server and console. </p>
  
  <p>In my <code>application.rb</code>, I have the following:</p>
  
  <pre><code>I18n.enforce_available_locales = true
  </code></pre>
  
  <p>Then I checked my console and got this:</p>
  
  <pre><code>[1] pry(main)&gt; I18n.available_locales
  =&gt; [:en, :de, :es, :fr, :ja, :pl, :"pt-BR", :ru, :sv, :"zh-CN", :"en-GB"]
  [2] pry(main)&gt; 
  </code></pre>
  
  <p>So the <code>:"en-GB"</code> was added successfully to my app's load path.</p>
  
  <p>But when I do this in my view:</p>
  
  <pre><code>&lt;%= number_to_currency(1234567890.506, :locale =&gt; :"en-GB") %&gt;
  </code></pre>
  
  <p>This is the error I get:</p>
  
  <pre><code>:"en-GB" is not a valid locale excluded from capture due to environment or should_capture callback
  
  ActionView::Template::Error (:"en-GB" is not a valid locale):
  </code></pre>
  
  <p>So still not working.</p>
  
  <p><strong>Update 3</strong></p>
  
  <p>My <code>en-GB.yml</code> file was taken directly from <a href="https://github.com/svenfuchs/rails-i18n/blob/master/rails/locale/en-GB.yml" rel="noreferrer">https://github.com/svenfuchs/rails-i18n/blob/master/rails/locale/en-GB.yml</a></p>
  
  <p>So it looks exactly like that. Yet I am still getting the same error:</p>
  
  <pre><code>ActionView::Template::Error (:"en-GB" is not a valid locale):
  </code></pre>