diff --git a/app/controllers/collections/entropies_controller.rb b/app/controllers/collections/entropies_controller.rb index d9ed904f8..4affaf5af 100644 --- a/app/controllers/collections/entropies_controller.rb +++ b/app/controllers/collections/entropies_controller.rb @@ -3,11 +3,6 @@ class Collections::EntropiesController < ApplicationController def update @collection.entropy.update!(entropy_params) - - render turbo_stream: [ - turbo_stream.replace([ @collection, :entropy ], partial: "collections/edit/auto_close", locals: { collection: @collection }), - turbo_stream_flash(notice: "Saved") - ] end private diff --git a/app/views/collections/entropies/update.turbo_stream.erb b/app/views/collections/entropies/update.turbo_stream.erb new file mode 100644 index 000000000..e8164aba4 --- /dev/null +++ b/app/views/collections/entropies/update.turbo_stream.erb @@ -0,0 +1,2 @@ +<%= turbo_stream.replace([ @collection, :entropy ], partial: "collections/edit/auto_close", locals: { collection: @collection }) %> +<%= turbo_stream_flash(notice: "Saved") %>