From c56cfab46d1bd11c391e19cb2f759527c566f806 Mon Sep 17 00:00:00 2001 From: chiu Date: Mon, 21 Oct 2019 20:15:29 +0800 Subject: [PATCH] Update galleries_controller.rb solve the upload problem for production mode --- app/controllers/admin/galleries_controller.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/controllers/admin/galleries_controller.rb b/app/controllers/admin/galleries_controller.rb index 4fa6fb6..b5d0a27 100644 --- a/app/controllers/admin/galleries_controller.rb +++ b/app/controllers/admin/galleries_controller.rb @@ -368,6 +368,7 @@ class Admin::GalleriesController < OrbitAdminController end def start_upload_process @@upload_success = true + sleep 0.01 render :json => {}.to_json end def init_upload @@ -380,6 +381,7 @@ class Admin::GalleriesController < OrbitAdminController render :json => {}.to_json end def upload_image + sleep 0.01 if !(@@image_unprocessed.nil?) album = Album.find(params[:album_id]) files = params['files']