Merge pull request #3165 from danielyxie/dev

Fix crash with new prompt
This commit is contained in:
hydroflame
2022-03-17 18:18:21 -04:00
committed by GitHub
3 changed files with 4 additions and 4 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -43,8 +43,8 @@ export function PromptManager(): React.ReactElement {
};
let PromptContent = PromptMenuBoolean;
if (prompt?.options?.type) PromptContent = types[prompt?.options?.type];
if (prompt?.options?.type && ["text", "select"].includes(prompt?.options?.type))
PromptContent = types[prompt?.options?.type];
const resolve = (value: boolean | string): void => {
prompt.resolve(value);
setPrompt(null);