mirror of
https://github.com/stoatchat/for-legacy-web.git
synced 2026-03-08 01:45:28 +00:00
Start migration to revolt.js@5.0.0.
200 error milestone
This commit is contained in:
@@ -3,8 +3,6 @@ import { Route, useHistory, useParams } from "react-router-dom";
|
||||
|
||||
import { Text } from "preact-i18n";
|
||||
|
||||
import { useData } from "../../mobx/State";
|
||||
|
||||
import { useClient } from "../../context/revoltjs/RevoltClient";
|
||||
import { getChannelName } from "../../context/revoltjs/util";
|
||||
|
||||
@@ -17,9 +15,8 @@ import Permissions from "./channel/Permissions";
|
||||
export default function ChannelSettings() {
|
||||
const { channel: cid } = useParams<{ channel: string }>();
|
||||
|
||||
const store = useData();
|
||||
const client = useClient();
|
||||
const channel = store.channels.get(cid);
|
||||
const channel = client.channels.get(cid);
|
||||
if (!channel) return null;
|
||||
if (
|
||||
channel.channel_type === "SavedMessages" ||
|
||||
@@ -53,7 +50,7 @@ export default function ChannelSettings() {
|
||||
category: (
|
||||
<Category
|
||||
variant="uniform"
|
||||
text={getChannelName(client, channel, true)}
|
||||
text={getChannelName(channel, true)}
|
||||
/>
|
||||
),
|
||||
id: "overview",
|
||||
|
||||
Reference in New Issue
Block a user