/** * Determine if a type is defined in the cofig or Get all the defined types in the cofig. * * @param string|null $type leave blank to get all types or give type to check if it exists; * * @return array|bool */ protected function defaultTypes($type = null) { return is_null($type) ? $this->config->defaultTypes() : in_array($type, $this->config->defaultTypes()); }