Bug 540 - InvalidNumberOfInput Error
Summary: InvalidNumberOfInput Error
Status: RESOLVED FIXED
Alias: None
Product: Group 13 Dating App System (vibing.com)
Classification: Unclassified
Component: Exception (show other bugs)
Version: 1
Hardware: PC Windows
: --- enhancement
Assignee: Varun
URL:
Depends on:
Blocks:
 
Reported: 2020-12-07 23:01 HKT by Varun
Modified: 2020-12-07 23:24 HKT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Varun 2020-12-07 23:01:21 HKT
The InvalidNumberInputClass does not throw an exception when invalid number of inputs are given. For example, I gave 10 inputs and it didn't throw an exception.
Comment 1 Phudis Dawieang 2020-12-07 23:24:53 HKT
The program does work properly when the input is more than the amount of intended input, however, as you mention, it should throw exception instead.

At first, the try-catch is covered the whole input retrieval (change separated input to the variable that will be used for the class creation) so that if the input is less than the amount intended, the InvalidNumberInputClass will invoke. Now, InvalidNumberInputClass will be thrown if the input amount not equal to 8.

The bug is now resolved.