Bug 549

Summary: Need to input twice for input except 'Y' when choosing whether to add attractions
Product: New-Territories-Cycle-Track-Navigation-System Reporter: shijialiu3-c
Component: CyclingModeAssignee: shijialiu3-c
Status: RESOLVED FIXED    
Severity: major    
Priority: Normal    
Version: 1.0   
Hardware: Macintosh   
OS: Mac OS   

Description shijialiu3-c 2021-11-07 16:24:12 HKT
Steps to reproduce:
1. Enter the cycling mode
2. When being asked whether to add attractions, input anything except 'Y', such as 'N' or 'a'

Actual result:
The software still waited for input and could not respond until the same content was input for the second time

Expected result:
The software proceeds to the next step or reports the invalid input.
Comment 1 shijialiu3-c 2021-11-07 16:26:51 HKT
Solution:
Use a variable to store input.nextLine() to avoid needing to read twice to make a judgement