From 7359995a3e7387bffe30448e1ac5c4de476a90c6 Mon Sep 17 00:00:00 2001 From: kPherox Date: Wed, 22 May 2019 16:04:19 +0900 Subject: [PATCH] Add listener for `add-timeline` to Main component --- src/components/Main.vue | 12 ++++++++++++ src/main/Timeline.ts | 4 ++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/components/Main.vue b/src/components/Main.vue index a64ac1c3..9784534d 100644 --- a/src/components/Main.vue +++ b/src/components/Main.vue @@ -9,6 +9,7 @@ diff --git a/src/main/Timeline.ts b/src/main/Timeline.ts index 42b52025..5a0bfa76 100644 --- a/src/main/Timeline.ts +++ b/src/main/Timeline.ts @@ -54,8 +54,8 @@ export default class Timeline { let newDoc = await db.insert(docs) event.sender.send(`add-timeline`, newDoc) } catch (err) { - let error = new Error("You cannot login already logined account.") - error.name = "ERROR_YOU_TRY_ANOTHER_ACCOUNT" + let error = new Error("Cannot save timeline.") + error.name = "ERROR_ADD_TIMELINE" event.sender.send(`add-timeline`, undefined, error) } }