updates and bug fix