protected static function checkValidSetting($attr, $settings, $key, $type)
{
if (!isset($settings[$key])) {
return;
}
$validateFunc = "is_{$type}";
if (!$validateFunc($settings[$key])) {
throw new InvalidConfigException("You must set the 'settings[\"{$key}\"]' property for '{$attr}' attribute as a valid {$type} " . "(no Closure method is supported).");
}
}