discourse/plugins/discourse-narrative-bot/lib/discourse_narrative_bot/magic_8_ball.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

12 lines
281 B
Ruby
Raw Normal View History

# frozen_string_literal: true
module DiscourseNarrativeBot
class Magic8Ball
def self.generate_answer
I18n.t("discourse_narrative_bot.magic_8_ball.result", result: I18n.t(
"discourse_narrative_bot.magic_8_ball.answers.#{rand(1..20)}"
))
end
end
end