- client: empty disallowed_clients
This commit is contained in:
parent
7a3eda02ce
commit
d8f8e6b94a
|
@ -55,7 +55,7 @@ export const toggleClientBlock = (type, ip) => async (dispatch) => {
|
||||||
const {
|
const {
|
||||||
allowed_clients, disallowed_clients, blocked_hosts,
|
allowed_clients, disallowed_clients, blocked_hosts,
|
||||||
} = await apiClient.getAccessList();
|
} = await apiClient.getAccessList();
|
||||||
let updatedDisallowedClients = disallowed_clients;
|
let updatedDisallowedClients = disallowed_clients || [];
|
||||||
|
|
||||||
if (type === ACTION.unblock && updatedDisallowedClients.includes(ip)) {
|
if (type === ACTION.unblock && updatedDisallowedClients.includes(ip)) {
|
||||||
updatedDisallowedClients = updatedDisallowedClients.filter(client => client !== ip);
|
updatedDisallowedClients = updatedDisallowedClients.filter(client => client !== ip);
|
||||||
|
|
Loading…
Reference in New Issue