removed packages
This commit is contained in:
@ -9,17 +9,17 @@ async function getInfo(data){
|
||||
return info
|
||||
}
|
||||
|
||||
|
||||
async function listAll(){
|
||||
|
||||
try{
|
||||
let hosts = await client.SMEMBERS('hosts');
|
||||
return hosts;
|
||||
}catch(error){
|
||||
return new Error(error);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
async function add(data){
|
||||
try{
|
||||
await client.SADD('hosts', data.host);
|
||||
@ -33,6 +33,7 @@ async function add(data){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
async function remove(data){
|
||||
try{
|
||||
await client.SREM('hosts', data.host);
|
||||
@ -43,4 +44,5 @@ async function remove(data){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
module.exports = {getInfo, listAll, add, remove};
|
||||
|
Reference in New Issue
Block a user