Sha256: 82a3317ef58cb22afd2a65fdcdc681087f9ee425fce8a472f4d2d9724ad54897
Contents?: true
Size: 378 Bytes
Versions: 20
Compression:
Stored size: 378 Bytes
Contents
class Admin::LocalesController < ApplicationController layout 'admin' def new end def create if I18n.add_locale(params[:name], params[:code]) redirect_to edit_admin_translation_path(params[:code]) else flash[:error] = "Invalid locale, please check the format and make sure the language is available." render :action => 'new' end end end
Version data entries
20 entries across 20 versions & 1 rubygems