Minor code cleanup
More cleanup
Further cleanup, rewriting alt account query