Astar little refactor