Fix error, pos could be null