From 3b5b1e98f05be67972a35e5d0456774ce7101ec6 Mon Sep 17 00:00:00 2001 From: classicalliu Date: Fri, 21 Sep 2018 19:07:38 +0800 Subject: [PATCH] fix brakeman bug --- app/models/cita_sync/persist.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/app/models/cita_sync/persist.rb b/app/models/cita_sync/persist.rb index 67887bd..48096ec 100644 --- a/app/models/cita_sync/persist.rb +++ b/app/models/cita_sync/persist.rb @@ -193,8 +193,10 @@ def save_blocks_with_infos # @return [void] def realtime_sync loop do - save_blocks_with_infos - rescue StandardError + begin + save_blocks_with_infos + rescue + end end end