Small fixes and cleanup (#238)