updated , fixed bugs