Minor code & logging cleanup