Remove E2EE setting

Since e2ee is enabled by default now
This commit is contained in:
David Baker
2023-10-13 10:30:06 +01:00
parent 515a73ce30
commit 5ef208e789
8 changed files with 8 additions and 62 deletions

View File

@@ -38,7 +38,7 @@ import { UserMenuContainer } from "../UserMenuContainer";
import { JoinExistingCallModal } from "./JoinExistingCallModal";
import { Caption } from "../typography/Typography";
import { Form } from "../form/Form";
import { useEnableE2EE, useOptInAnalytics } from "../settings/useSetting";
import { useOptInAnalytics } from "../settings/useSetting";
import { AnalyticsNotice } from "../analytics/AnalyticsNotice";
interface Props {
@@ -57,7 +57,6 @@ export const RegisteredView: FC<Props> = ({ client }) => {
() => setJoinExistingCallModalOpen(false),
[setJoinExistingCallModalOpen],
);
const [e2eeEnabled] = useEnableE2EE();
const onSubmit: FormEventHandler<HTMLFormElement> = useCallback(
(e: FormEvent) => {
@@ -73,11 +72,7 @@ export const RegisteredView: FC<Props> = ({ client }) => {
setError(undefined);
setLoading(true);
const createRoomResult = await createRoom(
client,
roomName,
e2eeEnabled ?? false,
);
const createRoomResult = await createRoom(client, roomName, true);
history.push(
getRelativeRoomUrl(
@@ -101,7 +96,7 @@ export const RegisteredView: FC<Props> = ({ client }) => {
}
});
},
[client, history, setJoinExistingCallModalOpen, e2eeEnabled],
[client, history, setJoinExistingCallModalOpen],
);
const recentRooms = useGroupCallRooms(client);

View File

@@ -41,7 +41,7 @@ import styles from "./UnauthenticatedView.module.css";
import commonStyles from "./common.module.css";
import { generateRandomName } from "../auth/generateRandomName";
import { AnalyticsNotice } from "../analytics/AnalyticsNotice";
import { useEnableE2EE, useOptInAnalytics } from "../settings/useSetting";
import { useOptInAnalytics } from "../settings/useSetting";
import { Config } from "../config/Config";
export const UnauthenticatedView: FC = () => {
@@ -62,8 +62,6 @@ export const UnauthenticatedView: FC = () => {
const history = useHistory();
const { t } = useTranslation();
const [e2eeEnabled] = useEnableE2EE();
const onSubmit: FormEventHandler<HTMLFormElement> = useCallback(
(e) => {
e.preventDefault();
@@ -86,11 +84,7 @@ export const UnauthenticatedView: FC = () => {
let createRoomResult;
try {
createRoomResult = await createRoom(
client,
roomName,
e2eeEnabled ?? false,
);
createRoomResult = await createRoom(client, roomName, true);
} catch (error) {
if (!setClient) {
throw error;
@@ -142,7 +136,6 @@ export const UnauthenticatedView: FC = () => {
history,
setJoinExistingCallModalOpen,
setClient,
e2eeEnabled,
],
);