Sha256: 9fbf840f11eb58dd9b8d95dcae6c9bf5de1135b1c26bc2680913b7fa2d42a100

Contents?: true

Size: 230 Bytes

Versions: 9

Compression:

Stored size: 230 Bytes

Contents

class UsersController < ApplicationController
    def remove_attachment
        attachment = ActiveStorage::Attachment.find(params[:attachment_id])
        attachment.purge
        redirect_back(fallback_location: "/")
    end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
administrate-field-active_storage-0.3.0 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.2.2 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.2.1 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.2.0 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.1.8 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.1.7 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.1.6 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.1.5 example-project/app/controllers/users_controller.rb
administrate-field-active_storage-0.1.4 example-project/app/controllers/users_controller.rb