Skip to content

Commit

Permalink
Add logging for firewall
Browse files Browse the repository at this point in the history
  • Loading branch information
hodgef committed Jan 1, 2025
1 parent 02f83ca commit 38c5683
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/components/Firewall/Firewall.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,11 @@ export const getFirewallBannedEntryId = async (ip: string): Promise<string> => {
},
});

return result[0].id;
if(apiker.debug){
console.log("getFirewallBannedEntryId", result);
}

return result?.[0]?.id || "";
};

export const firewallUnbanIP = async (ip: string) => {
Expand All @@ -61,6 +65,9 @@ export const firewallUnbanIP = async (ip: string) => {
const entryId = await getFirewallBannedEntryId(ip);

if(!entryId) {
if(apiker.debug){
console.log("firewallUnbanIP", "No entry found for ip", ip);
}
return;
}

Expand Down

0 comments on commit 38c5683

Please sign in to comment.