Issue #3380107 by acbramley: optionExists throws exception with incorrect type if option doesn't exist