Enhancements and bug fixs