eko / pihole-exporter

A Prometheus exporter for PI-Hole's Raspberry PI ad blocker
MIT License
900 stars 104 forks source link

Avoid Panic During Authentication #211

Closed csmarchbanks closed 9 months ago

csmarchbanks commented 9 months ago

If a request to the statistics endpoint fails then resp is nil causing a panic when looking for cookies. Properly handle errors when authenticating to avoid crashing the exporter.

Fixes: #158

eko commented 9 months ago

Thank you @csmarchbanks