repeat what the user says

This commit is contained in:
Loïc Bersier 2024-10-12 21:37:06 +02:00
parent c0dba0633b
commit 02ccacf3d0

21
lib/HahaCommands/say.ex Normal file
View file

@ -0,0 +1,21 @@
defmodule HahaYes.Commands.Say do
@moduledoc """
Repeat back what the user said
"""
alias Nostrum.Api
@doc """
Repeat back what the user said
## Example
User: h3h3 say how are you
Bot: how are you
"""
def execute(msg, _ws_state, args) do
Api.create_message(msg.channel_id, Enum.join(args, " "))
end
end