From 281b63c3f01d2a88249149fbad979e0593eb756d Mon Sep 17 00:00:00 2001 From: syuilo Date: Sun, 15 Aug 2021 22:10:05 +0900 Subject: [PATCH] fix(server): use insert instead of save --- src/services/chart/core.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/services/chart/core.ts b/src/services/chart/core.ts index 8fa0cd0aa..3c0526d2e 100644 --- a/src/services/chart/core.ts +++ b/src/services/chart/core.ts @@ -315,11 +315,11 @@ export default abstract class Chart> { if (currentLog != null) return currentLog; // 新規ログ挿入 - log = await this.repository.save({ + log = await this.repository.insert({ group: group, date: date, ...Chart.convertObjectToFlattenColumns(data) - }); + }).then(x => this.repository.findOneOrFail(x.identifiers[0])); logger.info(`${this.name + (group ? `:${group}` : '')}: New commit created`);