some basic improvements/corrections