From c22815551487138fbbc5ca75efb67c5713a4c825 Mon Sep 17 00:00:00 2001 From: syuilo Date: Thu, 13 Feb 2020 11:44:58 +0900 Subject: [PATCH] Fix #5930 --- CHANGELOG.md | 5 +++++ locales/ja-JP.yml | 2 ++ src/client/pages/messaging.vue | 8 ++++++++ 3 files changed, 15 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 02a227bcf..79fd22722 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,11 @@ ChangeLog ========= +unreleased +------------------- +### 🐛Fixes +* グループがない状態でグループチャットを開始しようとするとフリーズする問題を修正 + 12.8.0 (2020/02/13) -------------------- ### ✨Improvements diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index 02992b3b6..b1400d479 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -389,6 +389,8 @@ uiLanguage: "UIの表示言語" groupInvited: "グループに招待されました" aboutX: "{x}について" useOsNativeEmojis: "OSネイティブの絵文字を使用" +noGroups: "グループがありません" +joinOrCreateGroup: "既存のグループに招待してもらうか、新しくグループを作成してください。" _ago: unknown: "謎" diff --git a/src/client/pages/messaging.vue b/src/client/pages/messaging.vue index 4b6f49d82..e2880306f 100644 --- a/src/client/pages/messaging.vue +++ b/src/client/pages/messaging.vue @@ -139,6 +139,14 @@ export default Vue.extend({ async startGroup() { const groups1 = await this.$root.api('users/groups/owned'); const groups2 = await this.$root.api('users/groups/joined'); + if (groups1.length === 0 && groups2.length === 0) { + this.$root.dialog({ + type: 'warning', + title: this.$t('noGroups'), + text: this.$t('joinOrCreateGroup'), + }); + return; + } const { canceled, result: group } = await this.$root.dialog({ type: null, title: this.$t('group'),