fix: properly match main type
parent
f64c362c57
commit
418e7cc7f9
|
@ -89,7 +89,10 @@ class ShadowServerFetcher():
|
||||||
prefix = type_content.split('.')[0]
|
prefix = type_content.split('.')[0]
|
||||||
config['name'] = '{}-{}'.format(prefix, '_'.join(type_details))
|
config['name'] = '{}-{}'.format(prefix, '_'.join(type_details))
|
||||||
|
|
||||||
main_type = type_details[0]
|
if isinstance(type_details, str):
|
||||||
|
main_type = type_details
|
||||||
|
else:
|
||||||
|
main_type = type_details[0]
|
||||||
if main_type not in self.known_list_types:
|
if main_type not in self.known_list_types:
|
||||||
self.logger.warning(f'Unknown type: {main_type}. Please update the config creator script.')
|
self.logger.warning(f'Unknown type: {main_type}. Please update the config creator script.')
|
||||||
return None
|
return None
|
||||||
|
|
Loading…
Reference in New Issue