FIX: dialects var was not defined in prod (#617)

This commit is contained in:
Roman Rizzi 2024-05-13 17:28:27 -03:00 committed by GitHub
parent e22194f321
commit 8b00c47087
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 0 deletions

View File

@ -25,6 +25,8 @@ module DiscourseAi
end
def dialect_for(model_name)
dialects = []
if Rails.env.test? || Rails.env.development?
dialects = [DiscourseAi::Completions::Dialects::Fake]
end