From e85d611aa6ac40e1d30428617e6ad3bd0c1b0432 Mon Sep 17 00:00:00 2001 From: Tom Hacohen Date: Wed, 10 Jul 2019 12:09:43 +0100 Subject: [PATCH] Block sharing of old-style journals. --- src/Journals/JournalMembers.tsx | 25 +++++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) diff --git a/src/Journals/JournalMembers.tsx b/src/Journals/JournalMembers.tsx index 41c9d36..ef7054c 100644 --- a/src/Journals/JournalMembers.tsx +++ b/src/Journals/JournalMembers.tsx @@ -48,6 +48,7 @@ class JournalMembers extends React.PureComponent { const { members, revokeUser, addMemberOpen } = this.state; const info = syncJournal.collection; + const sharingAllowed = syncJournal.journal.version > 1; return ( <> @@ -86,12 +87,24 @@ class JournalMembers extends React.PureComponent { { addMemberOpen && - this.setState({ addMemberOpen: false })} - /> + (sharingAllowed ? + this.setState({ addMemberOpen: false })} + /> + : + this.setState({ addMemberOpen: false })} + onClose={() => this.setState({ addMemberOpen: false })} + > + Sharing of old-style journals is not allowed. In order to share this journal, create a new one, and copy its contents over using the "import" dialog. If you are experiencing any issues, please contact support. + + ) } );