+ client: added name for client
This commit is contained in:
committed by
Simon Zolin
parent
5210d214ec
commit
bc0b0af06b
@@ -203,3 +203,8 @@ export const redirectToCurrentProtocol = (values, httpPort = 80) => {
|
||||
};
|
||||
|
||||
export const normalizeTextarea = text => text && text.replace(/[;, ]/g, '\n').split('\n').filter(n => n);
|
||||
|
||||
export const getClientName = (clients, ip) => {
|
||||
const client = clients.find(item => ip === item.ip);
|
||||
return (client && client.name) || '';
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user