Client: PortalSettings: Security: fix
This commit is contained in:
parent
85fb071044
commit
7b101f267b
@ -152,7 +152,7 @@ const IpSecurity = (props) => {
|
||||
|
||||
saveToSessionStorage("defaultIPSettings", {
|
||||
enable: enable,
|
||||
ips: ips,
|
||||
ips: ipsObjectArr,
|
||||
});
|
||||
setShowReminder(false);
|
||||
toastr.success(t("SuccessfullySaveSettingsMessage"));
|
||||
|
@ -100,13 +100,13 @@ const UserFields = (props) => {
|
||||
let newInput1;
|
||||
let newInput2;
|
||||
|
||||
if (input.includes("-")) {
|
||||
if (input?.includes("-")) {
|
||||
newInput1 = input.split("-")[0];
|
||||
newInput2 = input.split("-")[1];
|
||||
}
|
||||
|
||||
const error = newInput2
|
||||
? input.split("-").length - 1 > 1 ||
|
||||
? input?.split("-").length - 1 > 1 ||
|
||||
!regexp.test(newInput1) ||
|
||||
!regexp.test(newInput2)
|
||||
: !regexp.test(input);
|
||||
|
Loading…
Reference in New Issue
Block a user