<commit_before>require 'warden'

module Monban
  class Railtie < Rails::Railtie
    config.app_middleware.use Warden::Manager do |config|
      Monban.initialize(config)
    end
  end
end<commit_msg>fixes error on trying to respond with http 401<commit_after>require 'warden'

module Monban
  class Railtie < Rails::Railtie
    config.app_middleware.use Warden::Manager do |config|
      Monban.initialize(config)
      config.failure_app = lambda{|e|[401, {"Content-Type" => "text/plain"}, ["Authorization Failed"]] }
    end
  end
end
{'fraction_non_alphanumeric': 0.10820895522388059, 'fraction_numerical': 0.011194029850746268, 'mean_word_length': 4.316831683168317, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 4, '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': '5591830', 'n_tokens_mistral': 183, 'n_tokens_neox': 168, 'n_words': 43}