Fix: Blacklist Nodes

This commit is contained in:
hirzidevs
2024-08-25 21:49:11 +07:00
parent d31b99f38f
commit 75d068a39b

View File

@@ -10,7 +10,7 @@ module.exports = async function getAllNodes() {
"Authorization": `Bearer ${config.panel.key}`
},
})
.then((res) => res.data.data.filter((node) => config.nodes_settings.blacklist.includes(node.attributes.id)))
.then((res) => res.data.data.filter((node) => !config.nodes_settings.blacklist.includes(node.attributes.id)))
.catch((error) => {
if (error.code === "ENOTFOUND") {
console.log(cliColor.cyanBright("[PteroStats] ") + cliColor.redBright("ENOTFOUND | DNS Error. Ensure your network connection and DNS server are functioning correctly."));