jamesnetherton / homehub-metrics-exporter

Prometheus exporter for the BT Home Hub router
MIT License
6 stars 3 forks source link

A bunch of smaller fixes #11

Closed Tenzer closed 4 years ago

Tenzer commented 4 years ago

These were mostly found via golangci-lint.

I've grouped the changes into individual commits which hopefully should make it easier to read.

I have mostly focused on changes which objectively increase the code quality and not looked much into code formatting since that's more subjective.

jamesnetherton commented 4 years ago

Thanks so much for this 👍

FWIW I'm not a huge fan of the ifElseChain rule that forces refactoring simple if / else expressions to case statements. But happy to live it with it here for now.

Tenzer commented 4 years ago

Thanks so much for this 👍

You're welcome!

FWIW I'm not a huge fan of the ifElseChain rule that forces refactoring simple if / else expressions to case statements. But happy to live it with it here for now.

Oh, I could have removed that from the PR if you had let me know before merging it.