From c15dd795c07ef462d86e1b35248915ec57f37c15 Mon Sep 17 00:00:00 2001 From: farhatahmad Date: Wed, 8 Jul 2020 10:25:55 -0400 Subject: [PATCH] Fixed issue causing panic task to reenable disabled servers --- lib/tasks/servers.rake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/tasks/servers.rake b/lib/tasks/servers.rake index 6429e98b..43a0107a 100644 --- a/lib/tasks/servers.rake +++ b/lib/tasks/servers.rake @@ -65,12 +65,12 @@ namespace :servers do end desc 'Mark a BigBlueButton server as unavailable, and clear all meetings from it' - task :panic, [:id, :keep_enabled] => :environment do |_t, args| - args.with_defaults(keep_enabled: false) + task :panic, [:id, :keep_state] => :environment do |_t, args| + args.with_defaults(keep_state: false) include ApiHelper server = Server.find(args.id) - server.enabled = args.keep_enabled + server.enabled = false unless args.keep_state server.save! meetings = Meeting.all.select { |m| m.server_id == server.id }