fixed bugs 4