integrate suggestions from @adrn