app/controllers/alchemy/admin/pages_controller.rb in alchemy_cms-4.0.0.beta vs app/controllers/alchemy/admin/pages_controller.rb in alchemy_cms-4.0.0.rc1
- old
+ new
@@ -1,5 +1,7 @@
+# frozen_string_literal: true
+
module Alchemy
module Admin
class PagesController < Alchemy::Admin::BaseController
include OnPageLayout::CallbacksRunner
@@ -185,10 +187,10 @@
#
def publish
# fetching page via before filter
@page.publish!
flash[:notice] = Alchemy.t(:page_published, name: @page.name)
- redirect_back_or_to_default(admin_pages_path)
+ redirect_back(fallback_location: admin_pages_path)
end
def copy_language_tree
language_root_to_copy_from.copy_children_to(copy_of_language_root)
flash[:notice] = Alchemy.t(:language_pages_copied)