chore: Enable Vietnamese in languages (#1314)

This commit is contained in:
Pranav Raj S 2020-10-05 22:53:24 +05:30 committed by GitHub
parent 399f9e004a
commit 11725de09a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -22,7 +22,8 @@ LANGUAGES_CONFIG = {
17 => { name: 'Romanian', iso_639_3_code: 'ron', iso_639_1_code: 'ro', enabled: true }, 17 => { name: 'Romanian', iso_639_3_code: 'ron', iso_639_1_code: 'ro', enabled: true },
18 => { name: 'Tamil', iso_639_3_code: 'tam', iso_639_1_code: 'ta', enabled: true }, 18 => { name: 'Tamil', iso_639_3_code: 'tam', iso_639_1_code: 'ta', enabled: true },
19 => { name: 'Persian', iso_639_3_code: 'fas', iso_639_1_code: 'fa', enabled: true }, 19 => { name: 'Persian', iso_639_3_code: 'fas', iso_639_1_code: 'fa', enabled: true },
20 => { name: 'Traditional Chinese', iso_639_3_code: 'zho', iso_639_1_code: 'zh_TW', enabled: true } 20 => { name: 'Traditional Chinese', iso_639_3_code: 'zho', iso_639_1_code: 'zh_TW', enabled: true },
21 => { name: 'Vietnamese', iso_639_3_code: 'vie', iso_639_1_code: 'vi', enabled: true }
}.filter { |_key, val| val[:enabled] }.freeze }.filter { |_key, val| val[:enabled] }.freeze
Rails.configuration.i18n.available_locales = LANGUAGES_CONFIG.map { |_index, lang| lang[:iso_639_1_code].to_sym } Rails.configuration.i18n.available_locales = LANGUAGES_CONFIG.map { |_index, lang| lang[:iso_639_1_code].to_sym }