String checkInput(String inp, [String] options, String def)
Arguments
inp: String to checkoptions: Valid inputsdef: Default if no valid input received
Usage
Checks that an input string is one of a defined list of options, returning it if so, returning a default value otherwise. This function accepts a Tainted string as inp, and so can be used to detaint.