module Workarea decorate Storefront::CartsController, with: :cart_sharing do def from if order = Order.find_by(sharable_token: params[:token]) rescue nil self.current_order = order flash[:success] = t('workarea.storefront.cart_sharing.success') else flash[:error] = t('workarea.storefront.cart_sharing.failure') end redirect_to cart_path end end end