protected function addPolymorphicRules($rules, $polymorphicKey, $type)
    {
        $rules["{$polymorphicKey}Type"] = "required|in:" . $this->getAllowedTypeString($polymorphicKey);
        // Jiu-jitsu here: Want to validate that the morph-to id has a valid entry in the relevant table,
        //   but this will throw an error if the polymorphic type returns an undefined lookup on a config key.
        //   If the lookup test fails, we just skip this rule and run the validator, which will fail on the invalid type
        if (array_key_exists($type, config('combine-core.validation.polymorphicTypes'))) {
            $rules["{$polymorphicKey}Id"] = "required|exists:" . config('combine-core.validation.polymorphicTypes')[$type] . ",id";
        }
        return $rules;
    }