mirror of
https://github.com/discourse/discourse-ai.git
synced 2025-07-01 03:52:34 +00:00
14 lines
321 B
Ruby
14 lines
321 B
Ruby
|
# frozen_string_literal: true
|
||
|
|
||
|
module DiscourseAi
|
||
|
module Translation
|
||
|
class VerboseLogger
|
||
|
def self.log(message, opts = { level: :warn })
|
||
|
if SiteSetting.ai_translation_verbose_logs
|
||
|
Rails.logger.send(opts[:level], "DiscourseAi::Translation: #{message}")
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
end
|