fix bugs of positions