some improvements based on editor feedback