Don't show option to submit bug reports if no endpoint configured
This commit is contained in:
parent
891ff86b49
commit
de0f2e65a5
2 changed files with 12 additions and 6 deletions
|
@ -9,6 +9,7 @@ import { useSubmitRageshake } from "./settings/submit-rageshake";
|
|||
import { ErrorMessage } from "./input/Input";
|
||||
import styles from "./FullScreenView.module.css";
|
||||
import { translatedError, TranslatedError } from "./TranslatedError";
|
||||
import { Config } from "./config/Config";
|
||||
|
||||
interface FullScreenViewProps {
|
||||
className?: string;
|
||||
|
@ -98,7 +99,7 @@ export function CrashView() {
|
|||
logsComponent = <div>{t("Thanks! We'll get right on it.")}</div>;
|
||||
} else if (sending) {
|
||||
logsComponent = <div>{t("Sending…")}</div>;
|
||||
} else {
|
||||
} else if (Config.get().rageshake?.submit_url) {
|
||||
logsComponent = (
|
||||
<Button
|
||||
size="lg"
|
||||
|
@ -115,7 +116,9 @@ export function CrashView() {
|
|||
<FullScreenView>
|
||||
<Trans>
|
||||
<h1>Oops, something's gone wrong.</h1>
|
||||
<p>Submitting debug logs will help us track down the problem.</p>
|
||||
{Config.get().rageshake?.submit_url && (
|
||||
<p>Submitting debug logs will help us track down the problem.</p>
|
||||
)}
|
||||
</Trans>
|
||||
<div className={styles.sendLogsSection}>{logsComponent}</div>
|
||||
{error && (
|
||||
|
|
|
@ -32,6 +32,7 @@ import { SettingsModal } from "../settings/SettingsModal";
|
|||
import { InviteModal } from "./InviteModal";
|
||||
import { TooltipTrigger } from "../Tooltip";
|
||||
import { FeedbackModal } from "./FeedbackModal";
|
||||
import { Config } from "../config/Config";
|
||||
|
||||
interface Props {
|
||||
roomIdOrAlias: string;
|
||||
|
@ -117,10 +118,12 @@ export function OverflowMenu({
|
|||
<SettingsIcon />
|
||||
<span>{t("Settings")}</span>
|
||||
</Item>
|
||||
<Item key="feedback" textValue={t("Submit feedback")}>
|
||||
<FeedbackIcon />
|
||||
<span>{t("Submit feedback")}</span>
|
||||
</Item>
|
||||
{Config.get().rageshake?.submit_url && (
|
||||
<Item key="feedback" textValue={t("Submit feedback")}>
|
||||
<FeedbackIcon />
|
||||
<span>{t("Submit feedback")}</span>
|
||||
</Item>
|
||||
)}
|
||||
</Menu>
|
||||
)}
|
||||
</PopoverMenuTrigger>
|
||||
|
|
Loading…
Add table
Reference in a new issue