Fix get token bug