Fix spaces feedback prompt wrongly showing when feedback is disabled (#9302)

pull/28217/head
Michael Telatynski 2022-09-20 17:59:29 +01:00 committed by GitHub
parent 9076152f79
commit 7e435eef13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -38,6 +38,7 @@ import SettingsStore from "../../../settings/SettingsStore";
import { getKeyBindingsManager } from "../../../KeyBindingsManager";
import { KeyBindingAction } from "../../../accessibility/KeyboardShortcuts";
import { MatrixClientPeg } from "../../../MatrixClientPeg";
import { UIFeature } from "../../../settings/UIFeature";
export const createSpace = async (
name: string,
@ -100,7 +101,7 @@ const nameToLocalpart = (name: string): string => {
// XXX: Temporary for the Spaces release only
export const SpaceFeedbackPrompt = ({ onClick }: { onClick?: () => void }) => {
if (!SdkConfig.get().bug_report_endpoint_url) return null;
if (!SdkConfig.get().bug_report_endpoint_url || !SettingsStore.getValue(UIFeature.Feedback)) return null;
return <div className="mx_SpaceFeedbackPrompt">
<span className="mx_SpaceFeedbackPrompt_text">{ _t("Spaces are a new feature.") }</span>