some corrections and tweaks