src/background: minor cleanup

* prefers dot notation when possible.
* removes whitespace
* semicolons
Nit: this should actually probably be formatted like if(...) {