InvisibleChat: improve encryption validator (#1646)
This commit is contained in:
parent
ca439e9e9a
commit
55b755b2df
|
@ -35,7 +35,7 @@ function EncModal(props: ModalProps) {
|
|||
const [password, setPassword] = React.useState("password");
|
||||
const [noCover, setNoCover] = React.useState(false);
|
||||
|
||||
const isValid = secret && (noCover || (cover && /\w \w/.test(cover)));
|
||||
const isValid = secret && (noCover || (cover && cover.trim().split(" ").length > 1));
|
||||
|
||||
return (
|
||||
<ModalRoot {...props}>
|
||||
|
|
Loading…
Reference in a new issue