Commit abad82ab authored by Cool Fire's avatar Cool Fire

Changes not saved to disk before previous commit

parent 5c702491
Pipeline #1576 passed with stage
in 2 minutes and 52 seconds
......@@ -44,9 +44,9 @@ class Manager2Api < Sinatra::Base
# rubocop:disable Metrics/AbcSize
# rubocop:disable Metrics/MethodLength
def notify_irc(message, channels = [settings.config['notify']['irc']['channel']])
message = "#{api_route_name}: #{message}"
uri = URI settings.config['notify']['irc']['endpoint']
def notify_irc(message, channels: [settings.config['notify']['irc']['channel']], prefix: true)
message = "#{api_route_name}: #{message}" if prefix
uri = URI settings.config['notify']['irc']['endpoint']
channels.each do |channel|
res = Net::HTTP.post_form(
......@@ -67,7 +67,7 @@ class Manager2Api < Sinatra::Base
# rubocop:enable Metrics/AbcSize
def notify_irc_admins(message)
notify_irc message, settings.config['notify']['irc']['admins']
notify_irc message, channels: settings.config['notify']['irc']['admins']
end
end
# rubocop:enable Metrics/BlockLength
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment