Typo correction, perfomance improvement, bug fix