The value 'spam' appears in both the requestTypesWithNoReason and the requestTypesWithOptionalReason arrays. (It is the only value which appears in both)
When determining whether the input field is required or disabled it currently checks only checks if it is in the requestTypesWithNoReason array. If the value is present it makes the field not required and disables the field. L3011-L3022
Simply removing 'spam' from requestTypesWithNoReason in L69 makes the spam option behave as a Optional Reason which I think was the intended behaviour:
When making a flag-pls for spam with the CV Request Generator the "Request Reason" field is disabled.
However, it is often helpful to explain less obvious spam.
The reason it is disabled is due to the declarations in lines 69 and 70:
The value
'spam'
appears in both therequestTypesWithNoReason
and therequestTypesWithOptionalReason
arrays. (It is the only value which appears in both)When determining whether the input field is required or disabled it currently checks only checks if it is in the
requestTypesWithNoReason
array. If the value is present it makes the field not required and disables the field. L3011-L3022Simply removing 'spam' from
requestTypesWithNoReason
in L69 makes the spam option behave as a Optional Reason which I think was the intended behaviour: