mirror of
https://github.com/fluent/fluentd-ui.git
synced 2025-08-12 01:07:09 +02:00
Simplify
This commit is contained in:
parent
dc8e4941bb
commit
5dd8ed5924
@ -22,7 +22,7 @@ module SettingHistoryConcern
|
||||
else
|
||||
flash = { danger: @fluentd.agent.log_tail(1).first }
|
||||
end
|
||||
after_dryrun_redirect(flash)
|
||||
redirect_to :back, flash: flash
|
||||
end
|
||||
|
||||
end
|
||||
|
@ -13,8 +13,4 @@ class Fluentd::Settings::HistoriesController < ApplicationController
|
||||
#Do not use BackupFile.new(params[:id]) because params[:id] can be any path.
|
||||
@backup_file = Fluentd::SettingArchive::BackupFile.find_by_file_id(@fluentd.agent.config_backup_dir, params[:id])
|
||||
end
|
||||
|
||||
def after_dryrun_redirect(flash)
|
||||
redirect_to daemon_setting_history_path(params[:id]), flash: flash
|
||||
end
|
||||
end
|
||||
|
@ -6,8 +6,4 @@ class Fluentd::Settings::RunningBackupController < ApplicationController
|
||||
def find_backup_file
|
||||
@backup_file = Fluentd::SettingArchive::BackupFile.new(@fluentd.agent.running_config_backup_file)
|
||||
end
|
||||
|
||||
def after_dryrun_redirect(flash)
|
||||
redirect_to daemon_setting_running_backup_path, flash: flash
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user