change function about the ts