diff --git a/frontend/src/components/group/GroupDeleteButton.tsx b/frontend/src/components/group/GroupDeleteButton.tsx
index 2fb82a5..8e2aea4 100644
--- a/frontend/src/components/group/GroupDeleteButton.tsx
+++ b/frontend/src/components/group/GroupDeleteButton.tsx
@@ -34,7 +34,7 @@ export function GroupDeleteButton({resource}: GroupDeleteButtonProps): JSX.Eleme
}
return (
-
+
Delete
)
diff --git a/frontend/src/components/group/GroupJoinButton.tsx b/frontend/src/components/group/GroupJoinButton.tsx
index 6066648..9fe29cc 100644
--- a/frontend/src/components/group/GroupJoinButton.tsx
+++ b/frontend/src/components/group/GroupJoinButton.tsx
@@ -15,7 +15,7 @@ export interface GroupJoinButtonProps {
export function GroupJoinButton({resource}: GroupJoinButtonProps): JSX.Element | null {
const authorization = useAuthorizationContext()
- const trueMembers = [resource.value.owner, ...resource.value.members]
+ const trueMembers = [...new Set([resource.value.owner, ...resource.value.members])]
const doJoin =
React.useCallback(
diff --git a/frontend/src/components/group/GroupLeaveButton.tsx b/frontend/src/components/group/GroupLeaveButton.tsx
index e6659fb..90f68f3 100644
--- a/frontend/src/components/group/GroupLeaveButton.tsx
+++ b/frontend/src/components/group/GroupLeaveButton.tsx
@@ -1,10 +1,10 @@
import {faUserMinus} from "@fortawesome/free-solid-svg-icons"
import {FontAwesomeIcon} from "@fortawesome/react-fontawesome"
-import {Button} from "@steffo/bluelib-react"
import * as React from "react"
import {useAuthorizationContext} from "../../contexts/authorization"
import {ManagedResource} from "../../hooks/useManagedViewSet"
import {SophonResearchGroup} from "../../types/SophonTypes"
+import {SafetyButton} from "../elements/SafetyButton"
export interface GroupLeaveButtonProps {
@@ -15,7 +15,7 @@ export interface GroupLeaveButtonProps {
export function GroupLeaveButton({resource}: GroupLeaveButtonProps): JSX.Element | null {
const authorization = useAuthorizationContext()
- const trueMembers = [resource.value.owner, ...resource.value.members]
+ const trueMembers = [...new Set([resource.value.owner, ...resource.value.members])]
const doLeave =
React.useCallback(
@@ -39,8 +39,8 @@ export function GroupLeaveButton({resource}: GroupLeaveButtonProps): JSX.Element
}
return (
-
+
)
}
diff --git a/frontend/src/components/group/GroupResourcePanel.tsx b/frontend/src/components/group/GroupResourcePanel.tsx
index 6c63e67..7687201 100644
--- a/frontend/src/components/group/GroupResourcePanel.tsx
+++ b/frontend/src/components/group/GroupResourcePanel.tsx
@@ -18,7 +18,7 @@ export interface GroupResourcePanelProps {
export function GroupResourcePanel({resource}: GroupResourcePanelProps): JSX.Element {
const icon = resource.value.access === "OPEN" ? faGlobe : faEnvelope
- const trueMembers = [resource.value.owner, ...resource.value.members]
+ const trueMembers = [...new Set([resource.value.owner, ...resource.value.members])]
return (
diff --git a/frontend/tsconfig.json b/frontend/tsconfig.json
index 27186b9..5027a9a 100644
--- a/frontend/tsconfig.json
+++ b/frontend/tsconfig.json
@@ -1,6 +1,6 @@
{
"compilerOptions": {
- "target": "es5",
+ "target": "es6",
"lib": [
"dom",
"dom.iterable",