More code clean-up

Bringing things up to WP standards