Checking the array key instead of value when setting options