40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
# File 'lib/esm/command/community/reset_cooldown.rb', line 40
def on_execute
check_for_owned_server! if arguments.server_id
check_for_valid_command!
check_for_registered_target_user!
reply(confirmation_embed)
response = ESM.bot.await_response(current_user, expected: [I18n.t("yes"), I18n.t("no")], timeout: 120)
return reply(I18n.t("commands.reset_cooldown.cancellation_reply")) if response.nil? || response.downcase == I18n.t("no").downcase
cooldown_query.each(&:reset!)
reply(success_embed)
end
|