<commit_before>module Kuhsaft
  module Cms
    class AdminController < ActionController::Base
      respond_to :html
      layout 'kuhsaft/cms/application'
      before_filter :set_content_locale

      def set_content_locale
        if params[:content_locale].present?
          I18n.locale = params[:content_locale]
        end
      end
    end
  end
end
<commit_msg>pass on content_locale by default<commit_after>module Kuhsaft
  module Cms
    class AdminController < ActionController::Base
      respond_to :html
      layout 'kuhsaft/cms/application'
      before_filter :set_content_locale

      def set_content_locale
        if params[:content_locale].present?
          I18n.locale = params[:content_locale]
        end
      end

      def url_options
        { content_locale: I18n.locale }.merge(super)
      end
    end
  end
end

{'fraction_non_alphanumeric': 0.06028368794326241, 'fraction_numerical': 0.0070921985815602835, 'mean_word_length': 2.6351931330472103, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5655569', 'n_tokens_mistral': 252, 'n_tokens_neox': 247, 'n_words': 58}