Files
fizzy/app/controllers/commands/undos_controller.rb
T
2025-05-06 10:49:46 +02:00

14 lines
266 B
Ruby

class Commands::UndosController < ApplicationController
before_action :set_command
def create
@command.undo!
redirect_back_or_to root_path
end
private
def set_command
@command = Current.user.commands.find(params[:command_id])
end
end