minor improvements (code cleanup)