minor fix and cleanup