for ts merging