fix(bot): 오류 발생 후 목록 갱신 추가

This commit is contained in:
caadiq 2026-01-05 22:31:56 +09:00
parent e216539f34
commit 4d37f0dfe2

View file

@ -105,14 +105,16 @@ function AdminScheduleBots() {
type: 'success', type: 'success',
message: `${data.addedCount}개 일정이 추가되었습니다. (전체 ${data.total}개)` message: `${data.addedCount}개 일정이 추가되었습니다. (전체 ${data.total}개)`
}); });
fetchBots();
} else { } else {
const data = await response.json(); const data = await response.json();
setToast({ type: 'error', message: data.error || '동기화 실패' }); setToast({ type: 'error', message: data.error || '동기화 실패' });
} }
// /
fetchBots();
} catch (error) { } catch (error) {
console.error('전체 동기화 오류:', error); console.error('전체 동기화 오류:', error);
setToast({ type: 'error', message: '동기화 중 오류가 발생했습니다.' }); setToast({ type: 'error', message: '동기화 중 오류가 발생했습니다.' });
fetchBots(); //
} finally { } finally {
setSyncing(null); setSyncing(null);
} }