bug fixes on previous